<!DOCTYPE html><html class="hide-aside" lang="zh-CN" data-theme="light"><head><meta charset="UTF-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><title>使用Github Action实现全自动部署 | Akilarの糖果屋</title><meta name="keywords" content="📁Hexo,💻git"><meta name="author" content="Akilar"><meta name="copyright" content="Akilar"><meta name="format-detection" content="telephone=no"><meta name="theme-color" content="#ffffff"><meta name="description" content="通过使用Github Action，将部署的步骤交给云端完成，每次只需Push即可坐等网站部署完毕。"><meta property="og:type" content="article"><meta property="og:title" content="使用Github Action实现全自动部署"><meta property="og:url" content="https://akilar.top/posts/f752c86d/"><meta property="og:site_name" content="Akilarの糖果屋"><meta property="og:description" content="通过使用Github Action，将部署的步骤交给云端完成，每次只需Push即可坐等网站部署完毕。"><meta property="og:locale" content="zh_CN"><meta property="og:image" content="https://img.zcool.cn/community/0125fe61e57b6111013e8cd04af4a2.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100"><meta property="article:published_time" content="2020-09-22T21:36:19.000Z"><meta property="article:modified_time" content="2022-09-18T16:15:19.000Z"><meta property="article:author" content="Akilar"><meta property="article:tag" content="📁Hexo"><meta property="article:tag" content="💻git"><meta name="twitter:card" content="summary"><meta name="twitter:image" content="https://img.zcool.cn/community/0125fe61e57b6111013e8cd04af4a2.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100"><link rel="shortcut icon" href="https://npm.elemecdn.com/akiblog@1.0.1/img/siteicon/favicon.png"><link rel="canonical" href="https://akilar.top/posts/f752c86d/" media="defer" onload='this.media="all"'><link rel="preconnect" href="//cdn.jsdelivr.net"><link rel="preconnect" href="//at.alicdn.com/"><link rel="preconnect" href="//cdnjs.cloudflare.com/"><link rel="preconnect" href="//sdk.51.la"><meta name="google_site_verification" content="INnh6jnldNB3hxjSoa9ut7Kd9xX9R6Mqe7807EJsbCc"><meta name="baidu-site-verification" content="code-6O1kXu3a70"><meta name="msvalidate.01" content="3A07763DBFF970229752E8DF7999C30D"><link rel="manifest" href="/manifest.json"><link rel="apple-touch-icon" sizes="180x180" href="https://npm.elemecdn.com/akiblog@1.0.1/img/image/siteicon/apple-touch-icon.png"><link rel="icon" type="image/png" sizes="32x32" href="https://npm.elemecdn.com/akiblog@1.0.1/img/siteicon/favicon-32x32.png"><link rel="icon" type="image/png" sizes="16x16" href="https://npm.elemecdn.com/akiblog@1.0.1/img/siteicon/favicon-16x16.png"><link rel="mask-icon" href="https://npm.elemecdn.com/akiblog@1.0.1/img/siteicon/safari-pinned-tab.svg" color="#5bbad5"><link rel="stylesheet" href="/css/index.css"><link rel="stylesheet" href="https://npm.elemecdn.com/@fortawesome/fontawesome-free@6.1.2/css/all.min.css" media="print" onload='this.media="all"'><link rel="stylesheet" href="https://npm.elemecdn.com/node-snackbar@0.1.16/dist/snackbar.min.css" media="print" onload='this.media="all"'><div class="js-pjax"><script charset="UTF-8" id="LA_COLLECT" src="https://sdk.51.la/js-sdk-pro.min.js"></script><script>LA.init({id:"JdyxkljyWpUOuTqt",ck:"JdyxkljyWpUOuTqt"})</script></div><script src="https://sdk.51.la/perf/js-sdk-perf.min.js" crossorigin="anonymous"></script><script>(new LingQue.Monitor).init({id:"JdzAJUCrdUGoOC7D"})</script><link rel="stylesheet" href="https://npm.elemecdn.com/akiblog@1.0.1/css/animate.min.css" media="print" onload='this.media="screen"'><link rel="stylesheet" href="https://npm.elemecdn.com/swiper@8.4.2/swiper-bundle.min.css" media="print" onload='this.media="all"'><script>const GLOBAL_CONFIG={root:"/",algolia:{appId:"STO7Z288QA",apiKey:"dbcfd77c89c49f19b42d68e572943881",indexName:"akilar",hits:{per_page:3},languages:{input_placeholder:"搜索文章",hits_empty:"找不到您查询的内容：${query}",hits_stats:"找到 ${hits} 条结果，用时 ${time} 毫秒"}},localSearch:void 0,translate:{defaultEncoding:2,translateDelay:0,msgToTraditionalChinese:"<i>繁</i><sapn>簡繁轉換</span>",msgToSimplifiedChinese:"<i>简</i><sapn>简繁转换</span>"},noticeOutdate:{limitDay:30,position:"top",messagePrev:"It has been",messageNext:"days since the last update, the content of the article may be outdated."},highlight:{plugin:"highlighjs",highlightCopy:!0,highlightLang:!0,highlightHeightLimit:130},copy:{success:"吾辈宣布你的剪贴板已经被我占领啦！",error:"抱歉，复制好像出了点问题。",noSupport:"你的浏览器好像不支持"},relativeDate:{homepage:!1,post:!1},runtime:"天",date_suffix:{just:"刚刚",min:"分钟前",hour:"小时前",day:"天前",month:"个月前"},copyright:void 0,lightbox:"mediumZoom",Snackbar:{chs_to_cht:"你已切换为繁体",cht_to_chs:"你已切换为简体",day_to_night:"你已切换为深色模式",night_to_day:"你已切换为浅色模式",bgLight:"#49B1F5",bgDark:"#1f1f1f",position:"top-center"},source:{justifiedGallery:{js:"https://npm.elemecdn.com/flickr-justified-gallery@2.1.2/dist/fjGallery.min.js",css:"https://npm.elemecdn.com/flickr-justified-gallery@2.1.2/dist/fjGallery.css"}},isPhotoFigcaption:!0,islazyload:!0,isAnchor:!1}</script><script id="config-diff">var GLOBAL_CONFIG_SITE={title:"使用Github Action实现全自动部署",isPost:!0,isHome:!1,isHighlightShrink:!1,isToc:!0,postUpdate:"2022-09-18 16:15:19"}</script><noscript><style>#nav{opacity:1}.justified-gallery img{opacity:1}#post-meta time,#recent-posts time{display:inline!important}</style></noscript><script>(e=>{e.saveToLocal={set:function(e,t,o){if(0===o)return;const a=864e5*o,n={value:t,expiry:(new Date).getTime()+a};localStorage.setItem(e,JSON.stringify(n))},get:function(e){const t=localStorage.getItem(e);if(!t)return;const o=JSON.parse(t);if(!((new Date).getTime()>o.expiry))return o.value;localStorage.removeItem(e)}},e.getScript=e=>new Promise((t,o)=>{const a=document.createElement("script");a.src=e,a.async=!0,a.onerror=o,a.onload=a.onreadystatechange=function(){const e=this.readyState;e&&"loaded"!==e&&"complete"!==e||(a.onload=a.onreadystatechange=null,t())},document.head.appendChild(a)}),e.activateDarkMode=function(){document.documentElement.setAttribute("data-theme","dark"),null!==document.querySelector('meta[name="theme-color"]')&&document.querySelector('meta[name="theme-color"]').setAttribute("content","#0d0d0d")},e.activateLightMode=function(){document.documentElement.setAttribute("data-theme","light"),null!==document.querySelector('meta[name="theme-color"]')&&document.querySelector('meta[name="theme-color"]').setAttribute("content","#ffffff")};const t=saveToLocal.get("theme"),o=(new Date).getHours();void 0===t?o<=6||o>=18?activateDarkMode():activateLightMode():"light"===t?activateLightMode():activateDarkMode();const a=saveToLocal.get("aside-status");void 0!==a&&("hide"===a?document.documentElement.classList.add("hide-aside"):document.documentElement.classList.remove("hide-aside"));/iPad|iPhone|iPod|Macintosh/.test(navigator.userAgent)&&document.documentElement.classList.add("apple")})(window)</script><link rel="stylesheet" href="https://npm.elemecdn.com/akiblog@1.0.1/css/custom.css" media="defer" onload='this.media="all"'><link rel="stylesheet" href="https://widget.heweather.net/simple/static/css/he-simple.css?v=1.4.0" media="defer" onload='this.media="all"'><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/SAO-Notify.js" async></script><script async src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/carousel-touch.js"></script><svg aria-hidden="true" style="position:absolute;overflow:hidden;width:0;height:0"><symbol id="icon-sun" viewBox="0 0 1024 1024"><path d="M960 512l-128 128v192h-192l-128 128-128-128H192v-192l-128-128 128-128V192h192l128-128 128 128h192v192z" fill="#FFD878" p-id="8420"></path><path d="M736 512a224 224 0 1 0-448 0 224 224 0 1 0 448 0z" fill="#FFE4A9" p-id="8421"></path><path d="M512 109.248 626.752 224H800v173.248L914.752 512 800 626.752V800h-173.248L512 914.752 397.248 800H224v-173.248L109.248 512 224 397.248V224h173.248L512 109.248M512 64l-128 128H192v192l-128 128 128 128v192h192l128 128 128-128h192v-192l128-128-128-128V192h-192l-128-128z" fill="#4D5152" p-id="8422"></path><path d="M512 320c105.888 0 192 86.112 192 192s-86.112 192-192 192-192-86.112-192-192 86.112-192 192-192m0-32a224 224 0 1 0 0 448 224 224 0 0 0 0-448z" fill="#4D5152" p-id="8423"></path></symbol><symbol id="icon-moon" viewBox="0 0 1024 1024"><path d="M611.370667 167.082667a445.013333 445.013333 0 0 1-38.4 161.834666 477.824 477.824 0 0 1-244.736 244.394667 445.141333 445.141333 0 0 1-161.109334 38.058667 85.077333 85.077333 0 0 0-65.066666 135.722666A462.08 462.08 0 1 0 747.093333 102.058667a85.077333 85.077333 0 0 0-135.722666 65.024z" fill="#FFB531" p-id="11345"></path><path d="M329.728 274.133333l35.157333-35.157333a21.333333 21.333333 0 1 0-30.165333-30.165333l-35.157333 35.157333-35.114667-35.157333a21.333333 21.333333 0 0 0-30.165333 30.165333l35.114666 35.157333-35.114666 35.157334a21.333333 21.333333 0 1 0 30.165333 30.165333l35.114667-35.157333 35.157333 35.157333a21.333333 21.333333 0 1 0 30.165333-30.165333z" fill="#030835" p-id="11346"></path></symbol></svg><link rel="stylesheet" href="https://npm.elemecdn.com/hexo-filter-gitcalendar/lib/gitcalendar.css" media="print" onload='this.media="all"'><meta name="generator" content="Hexo 6.2.0"><link rel="alternate" href="/atom.xml" title="Akilarの糖果屋" type="application/atom+xml"></head><body><div id="loading-box"><div class="ark-loading" id="ark-loading"><div class="ark-loading-top-container"><div class="ark-loading-top-left-flash"></div><div class="ark-loading-top-left-border"></div><div class="ark-loading-top-triangle"></div><div class="ark-loading-top-right-border"></div><div class="ark-loading-top-right-flash"></div></div><div class="ark-loading-bottom-container"><div class="ark-loading-bottom-left-border"></div><div class="ark-loading-bottom-left-triangle"></div><div class="ark-loading-bottom-center-border"></div><div class="ark-loading-bottom-right-triangle"></div><div class="ark-loading-bottom-right-border"></div></div><div class="ark-loading-main-container"><div class="ark-loading-content"><div class="ark-loading-power-left"></div><div class="ark-loading-center-left-border"></div><div class="ark-loading-cab-outside-border"><div class="ark-loading-cab-insideborder"><div class="ark-loading-cab-container"><div class="ark-loading-percentage"></div><div class="ark-loading-tip"></div></div></div></div><div class="ark-loading-center-right-border"></div><div class="ark-loading-power-right"></div></div></div></div></div><div id="web_bg"></div><div id="sidebar"><div id="menu-mask"></div><div id="sidebar-menus"><div class="avatar-img is-center"><img src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/author.webp" onerror='onerror=null,src="https://npm.elemecdn.com/akiblog@1.0.1/img/404.gif"' alt="avatar"></div><div class="sidebar-site-data site-data is-center"><a href="/archives/"><div class="headline">文章</div><div class="length-num">480</div></a><a href="/tags/"><div class="headline">标签</div><div class="length-num">63</div></a><a href="/categories/"><div class="headline">分类</div><div class="length-num">6</div></a></div><hr><div class="menus_items"><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-laptop"></use></svg> <span>博客</span></a></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/archives/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-Calendar"></use></svg> <span>时间轴</span></a></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/tags/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-strategy"></use></svg> <span>标签</span></a></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/fcircle/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-forumdiscusstion"></use></svg> <span>朋友圈</span></a></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/link/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-connection"></use></svg> <span>友人帐</span></a></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="/comments/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-letter"></use></svg> <span>留言板</span></a></div><div class="menus_item"><a class="site-page group faa-parent animated-hover" href="javascript:void(0);" rel="external nofollow noreferrer"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-hourglass"></use></svg> <span>生活</span><i class="fas fa-chevron-down expand"></i></a><ul class="menus_item_child"><li><a class="faa-parent animated-hover site-page child" href="/gallery/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-strategy"></use></svg> <span>相册</span></a></li><li><a class="faa-parent animated-hover site-page child" href="/bangumis/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-unicorn"></use></svg> <span>追番</span></a></li><li><a class="faa-parent animated-hover site-page child" href="/about/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-Achievement"></use></svg> <span>关于</span></a></li></ul></div><div class="menus_item"><a class="site-page faa-parent animated-hover" href="javascript:toRandomPost()" rel="external nofollow noreferrer"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-teamwork"></use></svg> <span>随便看看</span></a></div></div></div></div><div class="post" id="body-wrap"><header class="post-bg" id="page-header" style="background-image:url(https://img.zcool.cn/community/0125fe61e57b6111013e8cd04af4a2.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100)"><div class="menu-container" id="menu-container"><div class="menu-item"><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-laptop"></use></svg> <span>博客</span></a></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/archives/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-Calendar"></use></svg> <span>时间轴</span></a></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/tags/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-strategy"></use></svg> <span>标签</span></a></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/fcircle/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-forumdiscusstion"></use></svg> <span>朋友圈</span></a></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/link/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-connection"></use></svg> <span>友人帐</span></a></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="/comments/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-letter"></use></svg> <span>留言板</span></a></div><div class="menu-item-main has-child"><div class="menu-item-parent"><a class="site-page faa-parent animated-hover" href="javascript:void(0);" rel="external nofollow noreferrer"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-hourglass"></use></svg> <span>生活</span></a></div><div class="menu-item-child"><a class="faa-parent animated-hover site-page child" href="/gallery/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-strategy"></use></svg> <span>相册</span></a></div><div class="menu-item-child"><a class="faa-parent animated-hover site-page child" href="/bangumis/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-unicorn"></use></svg> <span>追番</span></a></div><div class="menu-item-child"><a class="faa-parent animated-hover site-page child" href="/about/"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-Achievement"></use></svg> <span>关于</span></a></div></div><div class="menu-item-main"><a class="site-page faa-parent animated-hover" href="javascript:toRandomPost()" rel="external nofollow noreferrer"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-teamwork"></use></svg> <span>随便看看</span></a></div></div><div class="top-bar"><div class="message-container"><div class="message-item message-weather" onclick="btf.scrollToDest(0,500)"><div class="message-weather-box" id="he-plugin-simple"></div></div><div class="message-item message-date" onclick="Navvisible()"><div class="message-date-box" id="message-date-box"></div><div class="message-title-box" id="message-title-box"><a id="site-name" title="通过使用Github Action，将部署的步骤交给云端完成，每次只需Push即可坐等网站部署完毕。">使用Github Action实现全自动部署</a></div></div><div class="message-item message-function"><div id="search-button"><a class="site-page social-icon search faa-parent animated-hover"><svg class="faa-tada icon" style="height:25px;width:25px" aria-hidden="true"><use xlink:href="#icon-analitic"></use></svg> <span>搜索</span></a></div><a class="icon-V hidden faa-parent animated-hover" onclick="switchNightMode()" title="昼夜切换"><svg class="faa-tada" width="25" height="25" viewBox="0 0 1024 1024"><use id="modeicon" xlink:href="#icon-moon"></use></svg></a><div id="toggle-menu"><a class="site-page faa-parent animated-hover"><svg class="faa-tada icon" style="height:25px;width:25px" aria-hidden="true"><use xlink:href="#icon-MobileApps"></use></svg></a></div></div></div></div><button class="active-button" onclick="Navvisible()"></button></div><div id="post-info"><h1 class="post-title">使用Github Action实现全自动部署<a class="post-edit-link" href="https://github.com/Akilarlxh/Hexo-blog-source/edit/master/source/_posts/Akilarの糖葫芦/优化日记/使用Github-action实现全自动部署.md" rel="external nofollow noreferrer" title="编辑" target="_blank"><i class="fas fa-feather-alt faa-tada animated-hover"></i></a></h1><div id="post-meta"><div class="meta-firstline"><span class="post-meta-date"><i class="far fa-calendar-alt fa-fw post-meta-icon"></i><span class="post-meta-label">发表于</span><time class="post-meta-date-created" datetime="2020-09-22T21:36:19.000Z" title="发表于 2020-09-22 21:36:19">2020-09-22</time><span class="post-meta-separator">|</span><i class="fas fa-history fa-fw post-meta-icon"></i><span class="post-meta-label">更新于</span><time class="post-meta-date-updated" datetime="2022-09-18T16:15:19.000Z" title="更新于 2022-09-18 16:15:19">2022-09-18</time></span><span class="post-meta-categories"><span class="post-meta-separator">|</span><i class="fas fa-inbox fa-fw post-meta-icon"></i><a class="post-meta-categories" href="/categories/%F0%9F%8D%A1Akilar%E3%81%AE%E7%B3%96%E8%91%AB%E8%8A%A6/">🍡Akilarの糖葫芦</a></span></div><div class="meta-secondline"><span class="post-meta-separator">|</span><span class="post-meta-wordcount"><i class="far fa-file-word fa-fw post-meta-icon"></i><span class="post-meta-label">字数总计:</span><span class="word-count">5.9k</span><span class="post-meta-separator">|</span><i class="far fa-clock fa-fw post-meta-icon"></i><span class="post-meta-label">阅读时长:</span><span>21分钟</span></span></div></div></div></header><main class="layout" id="content-inner"><div id="post"><article class="post-content" id="article-container"><details class="folding-tag" green><summary>更新日志</summary><div class="content"><div class="timeline undefined"><div class="timeline-item headline"><div class="timeline-item-title"><div class="item-circle"><p>更新记录</p></div></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2020-09-22:起草教程</p></div></div><div class="timeline-item-content"><div class="note info flat"><p>参考内容：</p><ol><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.zykjofficial.top/posts/ea8e8e59/">卓越科技-使用Github Actions 自动部署博客</a></li><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.flesx.cn/posts/17931.html">flexiston-GitHub Actions自动部署Hexo博客+Gulp压缩</a></li><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/ccknbc-actions/blog-butterfly/blob/master/.github/workflows/Deploy%20Hexo%20Public%20To%20Pages.yml">CCKNBC-GitHub Actions workflows</a></li></ol></div></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2020-11-27:细节更新</p></div></div><div class="timeline-item-content"><ol><li>使用更精确的描述区分源码仓库和博客仓库</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2021-01-16:脚本更新</p></div></div><div class="timeline-item-content"><ol><li>将git clone 使用的ssh链接改为https链接，避免权限报错。</li><li>感谢<a target="_blank" rel="noopener external nofollow noreferrer" href="https://sy233.xyz/">@Ayato233</a>提交的bug。</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2021-05-20:常见经典问题解决方案更新</p></div></div><div class="timeline-item-content"><ol><li>针对曾经做过git源码管理方案和第一次尝试使用git源码管理方案的读者分别编写配置方案。</li><li>常见经典问题处理方案归纳。</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2021-06-29:代码展开</p></div></div><div class="timeline-item-content"><ol><li>鉴于代码折叠以后，总有读者忽略关键步骤。故调整到推荐阅读展开。</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2022-06-09:调整教程变量组装</p></div></div><div class="timeline-item-content"><ol><li>将变量组装步骤更换为添加secrets。自主读取变量组装。避免萌新忘记更改变量的问题。</li><li>调整了部署方案，不再需要使用hexo-deployer-git插件</li><li>Coding已经不再提供集成部署功能。转为腾讯云webify，不推荐继续使用coding。</li><li>参考CCKNBC，使用git push origin master:master 默认从本地master分支推送至线上master分支，若没有则新建一个，这样脚本默认监测master分支变动触发，而推送指令默认推送至master。只要萌新不瞎改，就绝对可以成功触发github action。</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2022-09-14:更新配图</p></div></div><div class="timeline-item-content"><ol><li>更新配图，token生成勾选workflows选项和选择无期限配置。</li></ol></div></div><div class="timeline-item"><div class="timeline-item-title"><div class="item-circle"><p>2022-09-18:更新常见报错</p></div></div><div class="timeline-item-content"><ol><li>新增排查步骤，变量名问题及分支问题。</li><li>订正主题文件夹提交为子项目的解决步骤。</li></ol></div></div></div></div></details><h2 id="Github-Action简介"><a href="#Github-Action简介" class="headerlink" title="Github Action简介"></a>Github Action简介</h2><p><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/features/actions">Github Action</a>是 GitHub于2018年10月推出的一个CI\CD服务。<br></p><details class="folding-tag" red><summary>CI/CD解释</summary><div class="content"><div class="note info flat"><p>CI\CD 其实说的是三件事情：「持续集成（<code>Continuous Integration</code>）」、「持续交付（<code>Continuous Delivery</code>）」、「持续部署（<code>Continuous Deployment</code>）」。<br>因为「持续交付」和「持续部署」的英文缩写是一样的，所以这三件事情缩写成了 <code>CI\CD</code> 。</p></div></div></details><br>每次部署<code>Hexo</code>都需要运行指令三件套，随着文章越来越多，编译的时间也随之越来越长，通过<code>Github Action</code>，我们只需要在每次完成博客的编写或修改以后，将改动直接<code>push</code>到远程仓库，之后的编译部署的工作统统交给<code>CI</code>来完成即可，如果是看过<a href="/posts/54c08a4b/">Coding部署教程</a>的小伙伴，应该对这种持续部署的操作有所感触。<p></p><h2 id="教程常量声明"><a href="#教程常量声明" class="headerlink" title="教程常量声明"></a>教程常量声明</h2><div class="tip info"><p>感谢<a target="_blank" rel="noopener external nofollow noreferrer" href="https://menglei.xyz">@YML</a>的反馈。以下将使用特定的常量名来指代一些名词。此处建议读者直接使用教程内容的常量名。在最后再逐一搜索替换。这样可以避免对各种常量名的混淆。</p></div><div class="table-container"><table><thead><tr><th style="text-align:left">常量名</th><th style="text-align:left">常量释义</th></tr></thead><tbody><tr><td style="text-align:left"><strong>[Blogroot]</strong></td><td style="text-align:left">本地存放博客源码的文件夹路径</td></tr><tr><td style="text-align:left"><strong>[SourceRepo]</strong></td><td style="text-align:left">存放博客源码的私有仓库名</td></tr><tr><td style="text-align:left"><strong>[SiteBlogRepo]</strong></td><td style="text-align:left">存放编译好的博客页面的公有仓库名<br>Site指站点，教程中会替换成<br>Github、Gitee、Coding</td></tr><tr><td style="text-align:left"><strong>[SiteUsername]</strong></td><td style="text-align:left">用户名<br>Site指站点，教程中会替换成<br>Github、Gitee、Coding</td></tr><tr><td style="text-align:left"><strong>[SiteToken]</strong></td><td style="text-align:left">申请到的令牌码<br>Site指站点，教程中会替换成<br>Github、Gitee、Coding</td></tr><tr><td style="text-align:left"><strong>[GithubEmail]</strong></td><td style="text-align:left">与github绑定的主邮箱，建议使用Gmail</td></tr><tr><td style="text-align:left"><strong>[TokenUser]</strong></td><td style="text-align:left">Coding配置特有的令牌用户名</td></tr></tbody></table></div><figure class="highlight txt"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br></pre></td><td class="code"><pre><span class="line"># 在记事本中逐个记录，方便替换，以下为我的示例</span><br><span class="line">[Blogroot]：E:\Blogroot</span><br><span class="line"></span><br><span class="line">[SourceRepo]：Akilarlxh/Hexo-blog-source</span><br><span class="line"></span><br><span class="line">[SiteBlogRepo]</span><br><span class="line">  [GithubBlogRepo]：Akilarlxh.github.io</span><br><span class="line">  [GiteeBlogRepo]：akilar</span><br><span class="line">  [CodingBlogRepo]：akilar/akilar</span><br><span class="line"></span><br><span class="line">[SiteUsername]</span><br><span class="line">  [GithubUsername]：Akilarlxh</span><br><span class="line">  [GiteeUsername]：Akilar</span><br><span class="line">  [CodingUsername]：akilar</span><br><span class="line"></span><br><span class="line">[SiteToken]</span><br><span class="line">  [GithubToken]：15076c8eb9c874sad676bc9bfb13sadw86babf2</span><br><span class="line">  [GiteeToken]：f57acasdadgar4578603adas5d8w79bb</span><br><span class="line">  [CodingToken]：a4e45daf78as1f2670dcbbcfd5as7d8asd8cd66a77</span><br><span class="line"></span><br><span class="line">[GithubEmail]：akilarlxh@gmail.com</span><br><span class="line"></span><br><span class="line">[TokenUser]：RAxDiobbRi</span><br></pre></td></tr></table></figure><h2 id="Github-Action使用教程"><a href="#Github-Action使用教程" class="headerlink" title="Github Action使用教程"></a>Github Action使用教程</h2><h3 id="获取Token"><a href="#获取Token" class="headerlink" title="获取Token"></a>获取Token</h3><p>为了确保交由<code>Github Action</code>来持续部署时，<code>Github Action</code>具备足够的权限来进行<code>hexo deploy</code>操作,需要先获取<code>Token</code>，博主分别在<code>Github</code>、<code>Gitee</code>、<code>Coding</code>处部署了静态页面，所以也就需要获取这三处的<code>Token</code>。<br></p><div class="tabs" id="获取token"><ul class="nav-tabs"><li class="tab active"><button type="button" data-href="#获取token-1">⚛️Github</button></li><li class="tab"><button type="button" data-href="#获取token-2">🕉️Gitee</button></li><li class="tab"><button type="button" data-href="#获取token-3">✡️Coding</button></li></ul><div class="tab-contents"><div class="tab-item-content active" id="获取token-1"><p>访问<a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/settings/tokens">Github-&gt;头像（右上角）-&gt;Settings-&gt;Developer Settings-&gt;Personal access tokens</a>-&gt;<kbd>generate new token</kbd>,创建的<code>Token</code>名称随意，但必须勾选repo项和workflows项。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/PISlRDgrsBXzcLK.png" alt=""><br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/ca384d58.png" alt=""><br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/20200923085908748.png" alt=""></p><div class="note warning flat"><p><code>token</code>只会显示这一次，之后将无法查看，所以务必保证你已经记录下了<code>Token</code>。之后如果忘记了就只能重新生成重新配置了。</p></div><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="获取token-2"><p>访问<a target="_blank" rel="noopener external nofollow noreferrer" href="https://gitee.com/profile/personal_access_tokens">Gitee-&gt;头像（右上角）-&gt;设置-&gt;私人令牌</a>-&gt;生成新令牌<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/voHjeENlQOpFA6n.png" alt=""><br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/X6x8Tz9bgO7HNRP.png" alt=""></p><div class="note warning flat"><p><code>Token</code>只会显示这一次，之后将无法查看，所以务必保证你已经记录下了<code>Token</code>。之后如果忘记了就只能重新生成重新配置了。</p></div><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="获取token-3"><div class="note danger flat"><p>关于coding相关内容不再具备参考价值。Coding被腾讯云收购以后，现已停止提供静态页面部署功能，腾讯云将静态页面部署业务转移至<a target="_blank" rel="noopener external nofollow noreferrer" href="https://webify.cloudbase.net/">webify</a>，部署页面更加简单明了，速度也相当不错，当然，毕竟是腾讯家的产品，是按量计费的。</p></div><p>访问<a target="_blank" rel="noopener external nofollow noreferrer" href="https://coding.net/">Coding</a>-&gt;头像（右上角）-&gt;个人账户设置-&gt;访问令牌-&gt;新建令牌。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/PMgKRDZAUyfktzp.png" alt=""></p><div class="note warning flat"><p>Coding的配置还需要用到<strong>令牌用户名[TokenUser]</strong>，务必牢记，在接下来的<code>deploy</code>配置项中会写到。</p></div><p><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/aF4dLUomY6NkunZ.png" alt=""></p><p><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/HW96S8wOIP7YJxt.png" alt=""></p><div class="note warning flat"><p><strong>Token只会显示这一次</strong>，之后将无法查看，所以务必保证你已经记录下了Token。之后如果忘记了就只能重新生成重新配置了。</p></div><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div></div></div><p></p><h3 id="创建存放源码的私有仓库"><a href="#创建存放源码的私有仓库" class="headerlink" title="创建存放源码的私有仓库"></a>创建存放源码的私有仓库</h3><details class="folding-tag" orange><summary>点击查看</summary><div class="content"><p>我们需要创建一个用来存放<code>Hexo</code>博客源码的私有仓库<code>[SourceRepo]</code>，这点在<a href="/posts/6ef63e2d/">Win10</a>的<code>Hexo</code>博客搭建教程中有提到。为了保持教程的连贯，此处再写一遍。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/PZ7wmiuX8ae9rVK.png" alt=""><br>创建完成后，需要把博客的源码<code>push</code>到这里。首先获取远程仓库地址，此处虽然<code>SSH</code>和<code>HTTPS</code>均可。<code>SSH</code>在绑定过<code>ssh key</code>的设备上无需再输入密码，<code>HTTPS</code>则需要输入密码，但是<code>SSH</code>偶尔会遇到端口占用的情况。请自主选择。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/mpdUYJKcfWLQ2Eg.png" alt=""></p><div class="note info flat"><p>这里之所以是私有仓库，是因为在接下来的配置中会用到<code>Token</code>，如果<code>Token</code>被盗用，别人可以肆意操作你的github仓库内容，为了避免这一风险，才选择的博客源码闭源。</p></div></div></details><h3 id="配置Github-Action"><a href="#配置Github-Action" class="headerlink" title="配置Github Action"></a>配置Github Action</h3><div class="tabs" id="github-action配置"><ul class="nav-tabs"><li class="tab active"><button type="button" data-href="#github-action配置-1">⚓常规配置，适合初学者</button></li><li class="tab"><button type="button" data-href="#github-action配置-2">💫拓展：Gitee自动部署脚本配置&其余需要指令支持的拓展插件的配置</button></li></ul><div class="tab-contents"><div class="tab-item-content active" id="github-action配置-1"><ol><li>在<code>[Blogroot]</code>新建<code>.github</code>文件夹,注意开头是有个<code>.</code>的。然后在<code>.github</code>内新建<code>workflows</code>文件夹，再在<code>workflows</code>文件夹内新建<code>autodeploy.yml</code>,在<code>[Blogroot]/.github/workflows/autodeploy.yml</code>里面输入<figure class="highlight yml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br></pre></td><td class="code"><pre><span class="line"><span class="comment"># 当有改动推送到master分支时，启动Action</span></span><br><span class="line"><span class="attr">name:</span> <span class="string">自动部署</span></span><br><span class="line"></span><br><span class="line"><span class="attr">on:</span></span><br><span class="line">  <span class="attr">push:</span></span><br><span class="line">    <span class="attr">branches:</span></span><br><span class="line">      <span class="bullet">-</span> <span class="string">master</span> <span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br><span class="line"></span><br><span class="line">  <span class="attr">release:</span></span><br><span class="line">    <span class="attr">types:</span></span><br><span class="line">      <span class="bullet">-</span> <span class="string">published</span></span><br><span class="line"></span><br><span class="line"><span class="attr">jobs:</span></span><br><span class="line">  <span class="attr">deploy:</span></span><br><span class="line">    <span class="attr">runs-on:</span> <span class="string">ubuntu-latest</span></span><br><span class="line">    <span class="attr">steps:</span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">检查分支</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/checkout@v2</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">ref:</span> <span class="string">master</span> <span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装</span> <span class="string">Node</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/setup-node@v1</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">node-version:</span> <span class="string">&quot;12.x&quot;</span> <span class="comment">#action使用的node版本，建议大版本和本地保持一致。可以在本地用node -v查询版本号。</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装</span> <span class="string">Hexo</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        export TZ=&#x27;Asia/Shanghai&#x27;</span></span><br><span class="line"><span class="string">        npm install hexo-cli -g</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">缓存</span> <span class="string">Hexo</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/cache@v1</span></span><br><span class="line">      <span class="attr">id:</span> <span class="string">cache</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">path:</span> <span class="string">node_modules</span></span><br><span class="line">        <span class="attr">key:</span> <span class="string">$&#123;&#123;runner.OS&#125;&#125;-$&#123;&#123;hashFiles(&#x27;**/package-lock.json&#x27;)&#125;&#125;</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装依赖</span></span><br><span class="line">      <span class="attr">if:</span> <span class="string">steps.cache.outputs.cache-hit</span> <span class="type">!=</span> <span class="string">&#x27;true&#x27;</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        npm install --save</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">生成静态文件</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        hexo clean</span></span><br><span class="line"><span class="string">        hexo generate</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">部署</span> <span class="comment">#此处master:master 指从本地的master分支提交到远程仓库的master分支，若远程仓库没有对应分支则新建一个。如有其他需要，可以根据自己的需求更改。</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        cd ./public</span></span><br><span class="line"><span class="string">        git init</span></span><br><span class="line"><span class="string">        git config --global user.name &#x27;$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;&#x27;</span></span><br><span class="line"><span class="string">        git config --global user.email &#x27;$&#123;&#123; secrets.GITHUBEMAIL &#125;&#125;&#x27;</span></span><br><span class="line"><span class="string">        git add .</span></span><br><span class="line"><span class="string">        git commit -m &quot;$&#123;&#123; github.event.head_commit.message &#125;&#125; $(date +&quot;%Z %Y-%m-%d %A %H:%M:%S&quot;) Updated By Github Actions&quot;</span></span><br><span class="line"><span class="string">        git push --force --quiet &quot;https://$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;:$&#123;&#123; secrets.GITHUBTOKEN &#125;&#125;@github.com/$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;/$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;.github.io.git&quot; master:master</span></span><br><span class="line"><span class="string">        #git push --force --quiet &quot;https://$&#123;&#123; secrets.TOKENUSER &#125;&#125;:$&#123;&#123; secrets.CODINGTOKEN &#125;&#125;@e.coding.net/$&#123;&#123; secrets.CODINGUSERNAME &#125;&#125;/$&#123;&#123;  secrets.CODINGBLOGREPO &#125;&#125;.git&quot; master:master #coding部署写法，需要的自行取消注释</span></span><br><span class="line"><span class="string">        #git push --force --quiet &quot;https://$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;:$&#123;&#123; secrets.GITEETOKEN &#125;&#125;@gitee.com/$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;/$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;.git&quot; master:master #gitee部署写法，需要的自行取消注释</span></span><br></pre></td></tr></table></figure><div class="tip"><p>注意最后一行的<code>master:master</code>指从本地的master分支提交到远程仓库的master分支,需要根据你自己的实际情况进行调整。本地分支可以在git bash中看到。线上分支可以在提交仓库中查看。因为“政治正确”的原因，github在2020年10月将默认分支改为main。而git软件在本地默认创建的分支依然是master，所以若你线上仓库默认分支是main，这里应该写成master:main，表示从本地的master推送到远程的main。</p></div></li><li>之后需要自己到仓库的Settings-&gt;Secrets-&gt;actions 下添加环境变量，变量名参考脚本中出现的，依次添加。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/fdf9b9c9.png" alt=""><br>例如，需要部署在githubpage上，那么脚本中必要的变量为<br><code>GITHUBUSERNAME</code>、<code>GITHUBEMAIL</code>、<code>GITHUBTOKEN</code>，因此添加这三条变量。变量具体内容释义可以查看本文开头。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/d1fc6570.png" alt=""></li></ol><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="github-action配置-2"><div class="note info flat"><p>这里主要在于配置上文的安装依赖和生成静态文件，如果还安装了其他的需要在部署前输入相应指令的也可以按照这个思路来修改。<br>同时，此处还涉及到<code>Gitee的自动部署</code>，<strong>即使不开通Gitee pages pro，也可以完成自动更新</strong>。<br>详情可以访问<a target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.zykjofficial.top/posts/ea8e8e59/">卓越科技-使用Github Actions 自动部署博客</a><br>插件配置教程则是参考以下文档</p><ol><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/HCLonely/hexo-bilibili-bangumi">hexo-bilibili-bangumi</a>，使用该插件若是无效，请检查你的B站追番信息是否是公开的，在个人空间处设置。</li><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://demo.jerryc.me/posts/4073eda/#Gulp%E5%A3%93%E7%B8%AE">Butterfly文档-gulp压缩</a></li><li><a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/yanglbme/gitee-pages-action">Gitee Pages Action</a></li></ol></div><figure class="highlight yml"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br></pre></td><td class="code"><pre><span class="line"><span class="attr">name:</span> <span class="string">自动部署</span></span><br><span class="line"><span class="comment"># 当有改动推送到master分支时，启动Action</span></span><br><span class="line"><span class="attr">on:</span></span><br><span class="line">  <span class="attr">push:</span></span><br><span class="line">    <span class="attr">branches:</span></span><br><span class="line">      <span class="bullet">-</span> <span class="string">master</span></span><br><span class="line">      <span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br><span class="line">  <span class="attr">release:</span></span><br><span class="line">    <span class="attr">types:</span></span><br><span class="line">      <span class="bullet">-</span> <span class="string">published</span></span><br><span class="line"></span><br><span class="line"><span class="attr">jobs:</span></span><br><span class="line">  <span class="attr">deploy:</span></span><br><span class="line">    <span class="attr">runs-on:</span> <span class="string">ubuntu-latest</span></span><br><span class="line">    <span class="attr">steps:</span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">检查分支</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/checkout@v2</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">ref:</span> <span class="string">master</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装</span> <span class="string">Node</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/setup-node@v1</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">node-version:</span> <span class="string">&quot;12.x&quot;</span> <span class="comment">#action使用的node版本，建议大版本和本地保持一致。可以在本地用node -v查询版本号。</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装</span> <span class="string">Hexo</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        export TZ=&#x27;Asia/Shanghai&#x27;</span></span><br><span class="line"><span class="string">        npm install hexo-cli -g</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">缓存</span> <span class="string">Hexo</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">actions/cache@v1</span></span><br><span class="line">      <span class="attr">id:</span> <span class="string">cache</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">        <span class="attr">path:</span> <span class="string">node_modules</span></span><br><span class="line">        <span class="attr">key:</span> <span class="string">$&#123;&#123;runner.OS&#125;&#125;-$&#123;&#123;hashFiles(&#x27;**/package-lock.json&#x27;)&#125;&#125;</span></span><br><span class="line"></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">安装依赖</span></span><br><span class="line">      <span class="attr">if:</span> <span class="string">steps.cache.outputs.cache-hit</span> <span class="type">!=</span> <span class="string">&#x27;true&#x27;</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        npm install gulp-cli -g #全局安装gulp</span></span><br><span class="line"><span class="string">        npm install --save</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">生成静态文件</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        hexo clean</span></span><br><span class="line"><span class="string">        hexo bangumi -u #bilibili番剧更新</span></span><br><span class="line"><span class="string">        hexo generate</span></span><br><span class="line"><span class="string">        gulp</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">部署</span> <span class="comment">#此处master:master 指从本地的master分支提交到远程仓库的master分支，若远程仓库没有对应分支则新建一个。如有其他需要，可以根据自己的需求更改。</span></span><br><span class="line">      <span class="attr">run:</span> <span class="string">|</span></span><br><span class="line"><span class="string">        cd ./public</span></span><br><span class="line"><span class="string">        git init</span></span><br><span class="line"><span class="string">        git config --global user.name &#x27;$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;&#x27;</span></span><br><span class="line"><span class="string">        git config --global user.email &#x27;$&#123;&#123; secrets.GITHUBEMAIL &#125;&#125;&#x27;</span></span><br><span class="line"><span class="string">        git add .</span></span><br><span class="line"><span class="string">        git commit -m &quot;$&#123;&#123; github.event.head_commit.message &#125;&#125; $(date +&quot;%Z %Y-%m-%d %A %H:%M:%S&quot;) Updated By Github Actions&quot;</span></span><br><span class="line"><span class="string">        git push --force --quiet &quot;https://$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;:$&#123;&#123; secrets.GITHUBTOKEN &#125;&#125;@github.com/$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;/$&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;.github.io.git&quot; master:master</span></span><br><span class="line"><span class="string">        #git push --force --quiet &quot;https://$&#123;&#123; secrets.TOKENUSER &#125;&#125;:$&#123;&#123; secrets.CODINGTOKEN &#125;&#125;@e.coding.net/$&#123;&#123; secrets.CODINGUSERNAME &#125;&#125;/$&#123;&#123;  secrets.CODINGBLOGREPO &#125;&#125;.git&quot; master:master #coding部署写法，需要的自行取消注释</span></span><br><span class="line"><span class="string">        #git push --force --quiet &quot;https://$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;:$&#123;&#123; secrets.GITEETOKEN &#125;&#125;@gitee.com/$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;/$&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;.git&quot; master:master #gitee部署写法，需要的自行取消注释</span></span><br><span class="line"><span class="string"></span></span><br><span class="line">    <span class="comment">#同步到gitee这一步，如果上面写了推送到gitee仓库的git push指令了，那同步到 Gitee 这一块就不需要了。</span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">同步到</span> <span class="string">Gitee</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">wearerequired/git-mirror-action@master</span></span><br><span class="line">      <span class="attr">env:</span></span><br><span class="line">          <span class="comment"># 注意在github私有仓库的Settings-&gt;Secrets 配置 GITEE_RSA_PRIVATE_KEY</span></span><br><span class="line">          <span class="attr">SSH_PRIVATE_KEY:</span> <span class="string">$&#123;&#123;</span> <span class="string">secrets.GITEE_RSA_PRIVATE_KEY</span> <span class="string">&#125;&#125;</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">          <span class="comment"># 注意替换为你的 GitHub 源仓库地址</span></span><br><span class="line">          <span class="attr">source-repo:</span> <span class="string">&quot;git@github.com:$<span class="template-variable">&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;</span>/$<span class="template-variable">&#123;&#123; secrets.GITHUBUSERNAME &#125;&#125;</span>.github.io.git&quot;</span></span><br><span class="line">          <span class="comment"># 注意替换为你的 Gitee 目标仓库地址</span></span><br><span class="line">          <span class="attr">destination-repo:</span> <span class="string">&quot;git@gitee.com:$<span class="template-variable">&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;</span>/$<span class="template-variable">&#123;&#123; secrets.GITEEUSERNAME &#125;&#125;</span>.git&quot;</span></span><br><span class="line">    <span class="comment"># 这里就是模拟了一个点击更新网站按钮的动作。可以实现gitee page 自动更新。</span></span><br><span class="line">    <span class="bullet">-</span> <span class="attr">name:</span> <span class="string">构建</span> <span class="string">Gitee</span> <span class="string">Pages</span></span><br><span class="line">      <span class="attr">uses:</span> <span class="string">yanglbme/gitee-pages-action@master</span></span><br><span class="line">      <span class="attr">with:</span></span><br><span class="line">          <span class="comment"># 注意替换为你的 Gitee 用户名</span></span><br><span class="line">          <span class="attr">gitee-username:</span> <span class="string">$&#123;&#123;</span> <span class="string">secrets.GITEEUSERNAME</span> <span class="string">&#125;&#125;</span></span><br><span class="line">          <span class="comment"># 注意在在github私有仓库的Settings-&gt;Secrets 配置 GITEE_PASSWORD</span></span><br><span class="line">          <span class="attr">gitee-password:</span> <span class="string">$&#123;&#123;</span> <span class="string">secrets.GITEE_PASSWORD</span> <span class="string">&#125;&#125;</span></span><br><span class="line">          <span class="comment"># 注意替换为你的 Gitee 仓库</span></span><br><span class="line">          <span class="attr">gitee-repo:</span> <span class="string">$&#123;&#123;</span> <span class="string">secrets.GITEEUSERNAME</span> <span class="string">&#125;&#125;/$&#123;&#123;</span> <span class="string">secrets.GITEEUSERNAME</span> <span class="string">&#125;&#125;</span></span><br></pre></td></tr></table></figure><div class="tip"><p>注意最后一行的<code>master:master</code>指从本地的master分支提交到远程仓库的master分支,需要根据你自己的实际情况进行调整。本地分支可以在git bash中看到。线上分支可以在提交仓库中查看。因为“政治正确”的原因，github在2020年10月将默认分支改为main。而git软件在本地默认创建的分支依然是master，所以若你线上仓库默认分支是main，这里应该写成master:main，表示从本地的master推送到远程的main。</p></div><p><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/20200923101556168.png" alt=""></p><p>这里的<strong>GITEE_RSA_PRIVATE_KEY</strong>指你的个人密钥，在配置SSH-KEY时，我们用来与Github绑定的是公钥，而私钥存放在（以win10为例）<code>C:\Users\userneme\.ssh\id_rsa</code>文件内，内容格式类似于下方代码，使用时将包括<code>-----BEGIN RSA PRIVATE KEY-----</code>和<code>-----END RSA PRIVATE KEY-----</code>在内的全部内容都存放到变量值里。<br></p><figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br></pre></td><td class="code"><pre><span class="line">-----BEGIN RSA PRIVATE KEY-----</span><br><span class="line">MIIEogIBAAKCAQEApM/T7rRtc9sNcd7NNZHMOZU7e7322leY5JauIxJEgQYpdrfO</span><br><span class="line">vQB9PPpeMudAyCvAlaM?????????XO21G7RNejl4dLEflBh68TB93DlK/k/3KizMf</span><br><span class="line">jewpXU3HHpFSSyiIA7Mi8ur39ybbG4oWEHI/Mnjq?????????e5oiVvYNux2</span><br><span class="line">TazhAoGAL8h8XrB0t????????????????W2Ul4AomH1mu+rtIz2sQZdREVL4</span><br><span class="line">dskwWvzoGOyNBPreLXWHBY6fg34dhNaZvNDZPGGd3bK6arMRdzrAynQio0CE0zwm</span><br><span class="line">zJEo1tpUvqujmYMRnM1+jYHOPqU5sIvnEy5xovAzECPUSUs43Ag=</span><br><span class="line">-----END RSA PRIVATE KEY-----</span><br></pre></td></tr></table></figure><p></p><div class="note warning flat"><p>可能遇到的bug：</p><ol><li><p>Gitee用github action自动部署更新收到短信，提示异地登录需要验证码。<br>因为github action使用的是美国的服务器，所以，使用github action来远程更新gitee的站点部署时，会收到异地登陆的短信，提示需要验证码。这个在脚本作者的issues里有相应的解决方案:<a target="_blank" rel="noopener external nofollow noreferrer" href="https://github.com/yanglbme/gitee-pages-action/issues/6">登陆失败 #6</a></p><ul><li>在微信上搜索Gitee微信公众号，在微信公众号内绑定自己的Gitee账号，这样虽然还是会有异地登录提示，但是发过来的消息不再需要填写验证码，而且提醒若不是你在操作，请及时修改密码。（某种意义上就是我在操作，所以我选择不改密码2333）</li><li>使用VPN，通过美国IP登录一次Gitee。(一般第一步就能把问题解决了，用不到第二步。)</li></ul></li><li><p>Gitee部署失败<br>脚本的原理是用程序代替人工去点击Gitee Pages的更新按钮。所以需要你先手动做一次页面部署，确保有那个更新按钮在，脚本才有生效的前提。</p></li></ol></div><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div></div></div><h3 id="重新设置远程仓库和分支"><a href="#重新设置远程仓库和分支" class="headerlink" title="重新设置远程仓库和分支"></a>重新设置远程仓库和分支</h3><div class="tabs" id="branch"><ul class="nav-tabs"><li class="tab"><button type="button" data-href="#branch-1">🍾曾经做过git管理博客源码的操作</button></li><li class="tab active"><button type="button" data-href="#branch-2">🍼第一次使用git管理博客源码</button></li></ul><div class="tab-contents"><div class="tab-item-content" id="branch-1"><ol><li>添加屏蔽项<br>因为能够使用指令进行安装的内容不包括在需要提交的源码内，所有我们需要将这些内容添加到屏蔽项，表示不上传到github上。这样可以显著减少需要提交的文件量和加快提交速度。<br>打开<code>[Blogroot]/.gitignore</code>,输入以下内容：<figure class="highlight txt"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br></pre></td><td class="code"><pre><span class="line">.DS_Store</span><br><span class="line">Thumbs.db</span><br><span class="line">db.json</span><br><span class="line">*.log</span><br><span class="line">node_modules/</span><br><span class="line">public/</span><br><span class="line">.deploy*/</span><br><span class="line">.deploy_git*/</span><br><span class="line">.idea</span><br><span class="line">themes/butterfly/.git</span><br></pre></td></tr></table></figure>如果不是<code>butterfly</code>主题，记得替换最后一行内容为你自己当前使用的主题。</li><li>提交源码到私有仓库<code>[SourceRepo]</code><br>在博客根目录[Blogroot]下启动终端，使用git指令重设仓库地址。这样在新建仓库，我们仍旧可以保留珍贵的commit history，便于版本回滚。<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br></pre></td><td class="code"><pre><span class="line">git remote <span class="built_in">rm</span> origin <span class="comment"># 删除原有仓库链接</span></span><br><span class="line">git remote add origin git@github.com:[GithubUsername]/[SourceRepo].git <span class="comment">#[SourceRepo]为新的存放源码的github私有仓库</span></span><br><span class="line">git checkout -b master <span class="comment"># 切换到master分支，</span></span><br><span class="line"><span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br><span class="line"><span class="comment"># 如果不是，后面的所有设置的分支记得保持一致</span></span><br><span class="line">git add .</span><br><span class="line">git commit -m <span class="string">&quot;github action update&quot;</span></span><br><span class="line">git push origin master</span><br><span class="line"><span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br></pre></td></tr></table></figure></li><li>可能遇到的bug<br>因为<code>butterfly</code>主题文件夹下的<code>.git</code>文件夹的存在，那么主题文件夹会被识别子项目。从而无法被上传到源码仓库。若是遇到添加屏蔽项，但是还是无法正常上传主题文件夹的情况。请先将本地源码中的<code>themes</code>文件夹移动到别的目录下。然后<code>commit</code>一次。接着将<code>themes</code>文件夹移动回来，再<code>commit</code>一次。<div class="note danger flat"><p>要是还不行，那就删了<code>butterfly</code>主题文件夹下的<code>.git</code>文件夹，然后再重复上述的<code>commit</code>操作。</p></div></li></ol><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content active" id="branch-2"><ol><li>删除或者先把<code>[Blogroot]/themes/butterfly/.git</code>移动到非博客文件夹目录下,原因是主题文件夹下的<code>.git</code>文件夹的存在会导致其被识别成子项目，从而无法被上传到源码仓库。</li><li>在博客根目录<code>[Blogroot]</code>路径下运行指令<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br></pre></td><td class="code"><pre><span class="line">git init <span class="comment">#初始化</span></span><br><span class="line">git remote add origin git@github.com:[GithubUsername]/[SourceRepo].git <span class="comment">#[SourceRepo]为存放源码的github私有仓库</span></span><br><span class="line">git checkout -b master <span class="comment"># 切换到master分支，</span></span><br><span class="line"><span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br><span class="line"><span class="comment"># 如果不是，后面的所有设置的分支记得保持一致</span></span><br></pre></td></tr></table></figure></li><li>添加屏蔽项<br>因为能够使用指令进行安装的内容不包括在需要提交的源码内，所有我们需要将这些内容添加到屏蔽项，表示不上传到github上。这样可以显著减少需要提交的文件量和加快提交速度。<br>打开<code>[Blogroot]/.gitignore</code>,输入以下内容：<figure class="highlight txt"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br></pre></td><td class="code"><pre><span class="line">.DS_Store</span><br><span class="line">Thumbs.db</span><br><span class="line">db.json</span><br><span class="line">*.log</span><br><span class="line">node_modules/</span><br><span class="line">public/</span><br><span class="line">.deploy*/</span><br><span class="line">.deploy_git*/</span><br><span class="line">.idea</span><br><span class="line">themes/butterfly/.git</span><br></pre></td></tr></table></figure>如果不是<code>butterfly</code>主题，记得替换最后一行内容为你自己当前使用的主题。</li><li>之后再运行git提交指令，将博客源码提交到github上。牢记下方的三行指令，以后都是通过这个指令进行提交。<figure class="highlight bash"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br></pre></td><td class="code"><pre><span class="line">git add .</span><br><span class="line">git commit -m <span class="string">&quot;github action update&quot;</span> <span class="comment">#引号内的内容可以自行更改作为提交记录。</span></span><br><span class="line">git push origin master</span><br><span class="line"><span class="comment">#2020年10月后github新建仓库默认分支改为main，注意更改</span></span><br></pre></td></tr></table></figure></li><li>此时你的主题文件夹若已经被正常上传，并且你也添加了主题文件夹下的.git文件夹的屏蔽项。那你可以考虑把第二步移走或删除的<code>.git</code>放回来，用作以后升级。（不禁怀疑真的有人会去用这个方式来升级吗）</li></ol><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div></div></div><h3 id="查看部署情况"><a href="#查看部署情况" class="headerlink" title="查看部署情况"></a>查看部署情况</h3><details class="folding-tag" green><summary>点击查看</summary><div class="content"><p>此时，打开GIthub存放源码的私有仓库，找到action。<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/20200923095030252.png" alt=""><br>根据刚刚的Commit记录找到相应的任务<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/20200923095125814.png" alt=""><br>点击Deploy查看部署情况<br><img src="" data-lazy-src="https://npm.elemecdn.com/akilar-candyassets/image/20200923095219663.png" alt=""><br>若全部打钩，恭喜你，你现在可以享受自动部署的快感了。</p></div></details><h3 id="可能遇到的bug"><a href="#可能遇到的bug" class="headerlink" title="可能遇到的bug"></a>可能遇到的bug</h3><div class="note info flat"><p>最新教程已更新在提交至源码仓库章节前作为提示</p></div><div class="tabs" id="error"><ul class="nav-tabs"><li class="tab active"><button type="button" data-href="#error-1">⛔unknown block tag: "tagname"</button></li><li class="tab"><button type="button" data-href="#error-2">⛔spawn failed</button></li><li class="tab"><button type="button" data-href="#error-3">变量名称问题</button></li><li class="tab"><button type="button" data-href="#error-4">分支问题</button></li></ul><div class="tab-contents"><div class="tab-item-content active" id="error-1"><p></p><div class="note danger flat"><p>要是在github action部署时遇到<code>unknown block tag: &quot;tagname&quot;</code>这样的报错，说明你可能没有正确上传主题文件夹，也可能遇到安装依赖或生成页面失败的情况。</p></div><br>请按照以下思路逐一排查。<p></p><ol><li>是否将<code>node_modules</code>也上传到源码仓库<code>[SourceRepo]</code>了。源码仓库不需要有<code>node_modules</code>文件夹。</li><li>是否有将<code>[Blogroot]/themes/</code>下的主题文件夹上传，例如检查[SourceRepo]内的<code>[Blogroot]/themes/Butterfly</code>是否为空文件夹。为了能够正常编译页面，源码仓库需要有<code>[Blogroot]/themes/Butterfly</code>文件夹及它所包含的主题文件内容。<br>为了避免这两点，需要添加git屏蔽项。通过给<code>.gitignore</code>添加屏蔽项解决。<br>打开<code>[Blogroot]/.gitignore</code>,输入以下内容：<figure class="highlight x86asm"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br></pre></td><td class="code"><pre><span class="line"><span class="meta">.DS_Store</span></span><br><span class="line">Thumbs<span class="number">.</span><span class="built_in">db</span></span><br><span class="line"><span class="built_in">db</span><span class="number">.</span>json</span><br><span class="line">*.log</span><br><span class="line">node_modules/</span><br><span class="line"><span class="meta">public</span>/</span><br><span class="line"><span class="meta">.deploy</span>*/</span><br><span class="line"><span class="meta">.deploy_git</span>*/</span><br><span class="line"><span class="meta">.idea</span></span><br><span class="line">themes/butterfly/.git</span><br></pre></td></tr></table></figure></li><li>若是遇到添加屏蔽项，但是还是无法正常上传主题文件夹的情况。<ul><li>请先将本地源码中的<code>themes/butterfly</code>文件夹下的<code>.git</code>文件夹删除。</li><li>然后将<code>butterfly</code>文件夹移动到别的目录下。然后<code>commit</code>一次。</li><li>接着将<code>butterfly</code>文件夹移动回来，再<code>commit</code>一次。</li></ul></li></ol><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="error-2"><p></p><div class="note danger flat"><p>若是遇到<code>spawn failed</code>报错。在<code>github action</code>的配置中出现这一报错。一般是因为涉及到部署地址的配置项有误。</p></div><p></p><ol><li>首先排查你在<code>[Blogroot]\_config.yml</code>的<code>deploy</code>配置项是否按照上文<a href="#配置deploy项">配置deploy项</a>中的步骤正确组装配置链接。</li><li>其次排查<code>[Blogroot]\.github\workflows\autodeploy.yml</code>中各个关于仓库链接的配置内容，注意按照注释指引检查空格、分支等。</li><li>更多可能的因素和解决方案可以参考<a target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.zhheo.com/">@洪哥HEO</a>写的方案:<a target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.zhheo.com/p/128998ac.html">Hexo错误：spawn failed的解决方法</a>。</li></ol><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="error-3"><p>部分不愿意用教程给出的变量名的可能遇到未知bug，此处给出官方的命名规则：</p><p>以下规则适用于密码名称：</p><p>密钥名称只能包含字母数字字符（[a-z]、[A-Z]、[0-9]）或下划线 (_)。 不允许空格。</p><p>密钥名称不得以 <code>GITHUB_</code> 前缀开头。</p><p>密钥名称不能以数字开头。</p><p>密钥名称不区分大小写。</p><p>密钥名称在所创建的级别上必须是唯一的。</p><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div><div class="tab-item-content" id="error-4"><p>本地分支和线上分支不一致导致总是提交不上。<br>注意观察autodeploy.yml文件中，<br></p><figure class="highlight handlebars"><table><tr><td class="gutter"><pre><span class="line">1</span><br></pre></td><td class="code"><pre><span class="line"><span class="language-xml">git push --force --quiet &quot;https://$</span><span class="template-variable">&#123;&#123; <span class="name">secrets.GITHUBUSERNAME</span> &#125;&#125;</span><span class="language-xml">:$</span><span class="template-variable">&#123;&#123; <span class="name">secrets.GITHUBTOKEN</span> &#125;&#125;</span><span class="language-xml">@github.com/$</span><span class="template-variable">&#123;&#123; <span class="name">secrets.GITHUBUSERNAME</span> &#125;&#125;</span><span class="language-xml">/$</span><span class="template-variable">&#123;&#123; <span class="name">secrets.GITHUBUSERNAME</span> &#125;&#125;</span><span class="language-xml">.github.io.git&quot; master:master</span></span><br></pre></td></tr></table></figure><br>末尾的master:master指从本地的master分支提交到远程仓库的master分支。需要根据实际情况进行调整。本地的分支可在git bash中查看。线上的分支可在仓库查看。比如本地默认分支是master，线上默认分支是main，应该改成master:main。<br>会遇到这类问题，一般是有同学直接全局替换master为main导致。<p></p><button type="button" class="tab-to-top" aria-label="scroll to top"><i class="fas fa-arrow-up"></i></button></div></div></div><h3 id="后记"><a href="#后记" class="headerlink" title="后记"></a>后记</h3><p>这里可能有同学要问，github action有啥用？这不就是从<code>hexo cl &amp;&amp; hexo g &amp;&amp; hexo s</code>的三件套变成了<code>git add .</code>,<code>git commit -m &quot;commit content&quot;</code>,<code>git push</code>三件套吗？<br>其实github action的最大作用就是进一步提高速度和便携性，首先，配置要求提交源码这点，萌新小白就没必要再靠本地不断新建压缩包来备份源码了，借助git的版本管理，不管怎么改都可以快速回滚。<br>然后，git提交是增量更新，每次只提交新增或者删改的内容，而hexo deploy是在本地每次重新生成所有静态文件以后再整个提交。github action能帮我们节省大把时间，把最耗时的hexo generate和hexo deploy的工作丢给CI处理。让我们能够专心与编写博客内容，而不是水文3分钟，提交半小时。</p><h3 id="发散思维"><a href="#发散思维" class="headerlink" title="发散思维"></a>发散思维</h3><div class="note success flat"><p><code>Github action</code>只要监测到<code>master</code>分支有所变动就会启动部署，那么顺着这个思路，手机用户可以在网页Github进行小幅修改，例如修改错别字，调整布局之类的。保存后也会启动<code>Github action</code>，从而将内容部署到网页上去。</p><div class="note warning flat"><p>2020年10月后<code>github</code>新建仓库默认分支改为<code>main</code>，注意更改</p></div></div><h2 id="拓展内容"><a href="#拓展内容" class="headerlink" title="拓展内容"></a>拓展内容</h2><div class="note primary flat"><ol><li><a href="/posts/812734f8/">使用Vercel来加速Hexo博客</a></li><li><a href="/posts/54c08a4b/">使用Coding和github来实现双线部署</a></li><li><a href="/posts/6ff8c001/">使用Gitee提供镜像站支持</a></li></ol></div></article><div class="post-copyright"><div class="post-copyright__title"><span class="post-copyright-info"><h>使用Github Action实现全自动部署</h></span></div><div class="post-copyright__type"><span class="post-copyright-info"><a href="https://akilar.top/posts/f752c86d/">https://akilar.top/posts/f752c86d/</a></span></div><div class="post-copyright-m"><div class="post-copyright-m-info"><div class="post-copyright-a"><h>作者</h><div class="post-copyright-cc-info"><h>Akilar</h></div></div><div class="post-copyright-c"><h>发布于</h><div class="post-copyright-cc-info"><h>2020-09-22</h></div></div><div class="post-copyright-u"><h>更新于</h><div class="post-copyright-cc-info"><h>2022-09-18</h></div></div><div class="post-copyright-c"><h>许可协议</h><div class="post-copyright-cc-info"><a class="icon" rel="noopener external nofollow noreferrer" target="_blank" title="Creative Commons" href="https://creativecommons.org/"><i class="fab fa-creative-commons"></i></a><a rel="noopener external nofollow noreferrer" target="_blank" title="CC BY-NC-SA 4.0" href="https://creativecommons.org/licenses/by-nc-sa/4.0/">CC BY-NC-SA 4.0</a></div></div></div></div></div><div class="tag_share"><div class="post-meta__tag-list"><a class="post-meta__tags" href="/tags/%F0%9F%93%81Hexo/">📁Hexo</a><a class="post-meta__tags" href="/tags/%F0%9F%92%BBgit/">💻git</a></div><div class="post_share"></div></div><link rel="stylesheet" href="https://npm.elemecdn.com/akiblog@1.0.1/css/coin.css" media="defer" onload='this.media="all"'><div class="post-reward"><button class="tip-button reward-button"><span class="tip-button__text">不给糖果就捣蛋</span><div class="coin-wrapper"><div class="coin"><div class="coin__middle"></div><div class="coin__back"></div><div class="coin__front"></div></div></div><div class="reward-main"><ul class="reward-all"><li class="reward-item"><a href="https://npm.elemecdn.com/akiblog@1.0.1/img/wechat.png" rel="external nofollow noreferrer" target="_blank"><img class="post-qr-code-img" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/wechat.png" alt="wechat"></a><div class="post-qr-code-desc">wechat</div></li><li class="reward-item"><a href="https://npm.elemecdn.com/akiblog@1.0.1/img/alipay.png" rel="external nofollow noreferrer" target="_blank"><img class="post-qr-code-img" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/alipay.png" alt="alipay"></a><div class="post-qr-code-desc">alipay</div></li></ul></div></button></div><audio id="coinAudio" src="https://npm.elemecdn.com/akilar-candyassets/audio/aowu.m4a"></audio><script defer src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/coin.js"></script><nav class="pagination-post" id="pagination"><div class="prev-post pull-left"><a href="javascript:void(0);" rel="external nofollow noreferrer" onclick="SAONotify(&quot;Prev Post&quot;,&quot;是否跳转至上一篇：&lt;br&gt;使用Coding和Github来实现双线部署&quot;,&quot;pjax.loadUrl('/posts/54c08a4b/')&quot;)" title="使用Coding和Github来实现双线部署"><i class="fas fa-chevron-left prev-icon"><div class="prev-label">上一篇</div></i></a><div class="pagination-card"><img class="prev-cover" src="" data-lazy-src="https://img.zcool.cn/community/01593e61dd8ce411013e8cd0aa8bab.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" onerror='onerror=null,src="https://npm.elemecdn.com/akiblog@1.0.1/img/loading.gif"' alt="cover of previous post"><div class="pagination-info"><div class="label">上一篇</div><div class="prev_info">使用Coding和Github来实现双线部署</div></div></div></div><div class="next-post pull-right"><a href="javascript:void(0);" rel="external nofollow noreferrer" onclick="SAONotify(&quot;Next Post&quot;,&quot;是否跳转至下一篇：&lt;br&gt;平滑升级魔改后的Hexo主题&quot;,&quot;pjax.loadUrl('/posts/bbf68ad4/')&quot;)" title="平滑升级魔改后的Hexo主题"><i class="fas fa-chevron-right next-icon"><div class="next-label">下一篇</div></i></a><div class="pagination-card"><img class="next-cover" src="" data-lazy-src="https://img.zcool.cn/community/01593e61dd8ce411013e8cd0aa8bab.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" onerror='onerror=null,src="https://npm.elemecdn.com/akiblog@1.0.1/img/loading.gif"' alt="cover of next post"><div class="pagination-info"><div class="label">下一篇</div><div class="next_info">平滑升级魔改后的Hexo主题</div></div></div></div></nav><div class="business-center"><div class="business-card"><div class="business-flip"><div class="business-front"><div class="business-strip-bottom"></div><div class="business-strip-top"></div><img class="business-logo" width="80" height="80" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/cardcode.png" alt="cardcode"><div class="business-Invitation">Invitation</div><div class="business-chip"><div class="business-chip-line"></div><div class="business-chip-line"></div><div class="business-chip-line"></div><div class="business-chip-line"></div><div class="business-chip-main"></div></div><svg class="business-wave" viewBox="0 3.71 26.959 38.787" width="26.959" height="38.787" fill="white"><path d="M19.709 3.719c.266.043.5.187.656.406 4.125 5.207 6.594 11.781 6.594 18.938 0 7.156-2.469 13.73-6.594 18.937-.195.336-.57.531-.957.492a.9946.9946 0 0 1-.851-.66c-.129-.367-.035-.777.246-1.051 3.855-4.867 6.156-11.023 6.156-17.718 0-6.696-2.301-12.852-6.156-17.719-.262-.317-.301-.762-.102-1.121.204-.36.602-.559 1.008-.504z"></path><path d="M13.74 7.563c.231.039.442.164.594.343 3.508 4.059 5.625 9.371 5.625 15.157 0 5.785-2.113 11.097-5.625 15.156-.363.422-1 .472-1.422.109-.422-.363-.472-1-.109-1.422 3.211-3.711 5.156-8.551 5.156-13.843 0-5.293-1.949-10.133-5.156-13.844-.27-.309-.324-.75-.141-1.114.188-.367.578-.582.985-.542h.093z"></path><path d="M7.584 11.438c.227.031.438.144.594.312 2.953 2.863 4.781 6.875 4.781 11.313 0 4.433-1.828 8.449-4.781 11.312-.398.387-1.035.383-1.422-.016-.387-.398-.383-1.035.016-1.421 2.582-2.504 4.187-5.993 4.187-9.875 0-3.883-1.605-7.372-4.187-9.875-.321-.282-.426-.739-.266-1.133.164-.395.559-.641.984-.617h.094zM1.178 15.531c.121.02.238.063.344.125 2.633 1.414 4.437 4.215 4.437 7.407 0 3.195-1.797 5.996-4.437 7.406-.492.258-1.102.07-1.36-.422-.257-.492-.07-1.102.422-1.359 2.012-1.075 3.375-3.176 3.375-5.625 0-2.446-1.371-4.551-3.375-5.625-.441-.204-.676-.692-.551-1.165.122-.468.567-.785 1.051-.742h.094z"></path></svg><div class="business-card-number"><div class="business-section">Akilar</div><div class="business-section">589330978</div></div><div class="business-end"><span class="business-end-text">created:</span><span class="business-end-date">14/10/2022</span></div><div class="business-card-holder">Welcome to Candyhome</div><div class="business-master"><div class="business-circle business-master-red"></div><div class="business-circle business-master-yellow"></div></div></div><div class="business-back"><div class="business-strip-black"></div><div class="business-ccv"><label>sitelink</label><div><a target="_blank" rel="noopener external nofollow noreferrer" href="https://jq.qq.com/?_wv=1027&k=5o4Iga8D">加入群聊【🧊Akilarの糖果屋🍭】</a></div></div><div class="business-terms"><p>Use this card to join the candyhome and participate in a pleasant discussion together .</p><p>Welcome to Akilar's candyhome,wish you a nice day .</p></div></div></div></div></div><hr><div id="post-comment"><div class="comment-head"><div class="comment-headline"><i class="fas fa-comments fa-fw"></i> <span>评论</span></div></div><div class="comment-wrap"><div><div id="twikoo-wrap"></div></div></div></div></div><div class="aside-content" id="aside-content"><div class="card-widget card-author"><div class="item-headline"><i class="fa-solid fa-circle-user"></i><span>作者信息</span></div><div class="author-main-content"><div class="author-check-content"><label class="author-info" for="author-info"><input id="author-info" type="checkbox" name="author-info"><div class="author-avatar"><img src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/author.webp" onerror='this.onerror=null,this.src="https://npm.elemecdn.com/akiblog@1.0.1/img/404.gif"' alt="avatar"></div><div class="author-name">Akilar</div></label></div><div class="author-switch-content"><input class="switch-content" type="radio" name="switch-content" value="description"><label class="author-description-box"><div class="author-description">流水幽吟绕耳边，<br>煦风馨语抚心弦，<br>挥臂欲揽冰钩月，<br>银星斟酌醉人涎。</div></label><input class="switch-content" type="radio" name="switch-content" value="social" checked><label class="author-social-box"><a class="card-author-button" target="_blank" rel="noopener external nofollow noreferrer" href="https://jq.qq.com/?_wv=1027&amp;k=tNuEdliQ"><i class="fa fa-paper-plane faa-tada"></i><span>加入糖果屋群聊</span></a><div class="social-icons"><a class="social-icon faa-parent animated-hover" href="https://github.com/Akilarlxh" rel="external nofollow noreferrer" target="_blank" title="Github"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-identity-01"></use></svg></a><a class="social-icon faa-parent animated-hover" href="mailto:Akilarlxh@gmail.com" rel="external nofollow noreferrer" target="_blank" title="Email"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-Openmail-01"></use></svg></a><a class="social-icon faa-parent animated-hover" href="https://space.bilibili.com/22976782" rel="external nofollow noreferrer" target="_blank" title="Bilibili"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-film-01"></use></svg></a><a class="social-icon faa-parent animated-hover" href="https://music.163.com/#/user/home?id=292643778" rel="external nofollow noreferrer" target="_blank" title="Cloudmusic"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-songlist-01"></use></svg></a><a class="social-icon faa-parent animated-hover" href="/atom.xml" target="_blank" title="RSS"><svg class="icon faa-tada" aria-hidden="true"><use xlink:href="#icon-pushpin-01"></use></svg></a></div></label><input class="switch-content" type="radio" name="switch-content" value="site-data"><label class="author-data-box"><div class="site-data"><a class="data-item" href="/archives/"><div class="data-name">文章</div><div class="data-length">480</div></a><a class="data-item" href="/tags/"><div class="data-name">标签</div><div class="data-length">63</div></a><a class="data-item" href="/categories/"><div class="data-name">分类</div><div class="data-length">6</div></a></div></label></div></div></div><div class="sticky_layout"><div class="card-widget" id="card-toc"><div class="item-headline"><i class="fas fa-stream"></i><span>目录</span><span class="toc-percentage"></span></div><div class="toc-content"><ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#Github-Action%E7%AE%80%E4%BB%8B"><span class="toc-number">1.</span> <span class="toc-text">Github Action简介</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E6%95%99%E7%A8%8B%E5%B8%B8%E9%87%8F%E5%A3%B0%E6%98%8E"><span class="toc-number">2.</span> <span class="toc-text">教程常量声明</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#Github-Action%E4%BD%BF%E7%94%A8%E6%95%99%E7%A8%8B"><span class="toc-number">3.</span> <span class="toc-text">Github Action使用教程</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E8%8E%B7%E5%8F%96Token"><span class="toc-number">3.1.</span> <span class="toc-text">获取Token</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%88%9B%E5%BB%BA%E5%AD%98%E6%94%BE%E6%BA%90%E7%A0%81%E7%9A%84%E7%A7%81%E6%9C%89%E4%BB%93%E5%BA%93"><span class="toc-number">3.2.</span> <span class="toc-text">创建存放源码的私有仓库</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E9%85%8D%E7%BD%AEGithub-Action"><span class="toc-number">3.3.</span> <span class="toc-text">配置Github Action</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E9%87%8D%E6%96%B0%E8%AE%BE%E7%BD%AE%E8%BF%9C%E7%A8%8B%E4%BB%93%E5%BA%93%E5%92%8C%E5%88%86%E6%94%AF"><span class="toc-number">3.4.</span> <span class="toc-text">重新设置远程仓库和分支</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%9F%A5%E7%9C%8B%E9%83%A8%E7%BD%B2%E6%83%85%E5%86%B5"><span class="toc-number">3.5.</span> <span class="toc-text">查看部署情况</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%8F%AF%E8%83%BD%E9%81%87%E5%88%B0%E7%9A%84bug"><span class="toc-number">3.6.</span> <span class="toc-text">可能遇到的bug</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%90%8E%E8%AE%B0"><span class="toc-number">3.7.</span> <span class="toc-text">后记</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E5%8F%91%E6%95%A3%E6%80%9D%E7%BB%B4"><span class="toc-number">3.8.</span> <span class="toc-text">发散思维</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E6%8B%93%E5%B1%95%E5%86%85%E5%AE%B9"><span class="toc-number">4.</span> <span class="toc-text">拓展内容</span></a></li></ol></div></div><div class="card-widget card-recommend-post"><div class="item-headline"><i class="fas fa-dharmachakra"></i><span>相关推荐</span></div><div class="aside-list"><div class="aside-list-item"><a class="thumbnail" href="/posts/54c08a4b/" title="只靠Github和Vercel的速度还是有些捉襟见肘，因此再增加一条Coding来为国内访问节点提供线路。"><img src="" data-lazy-src="https://img.zcool.cn/community/01593e61dd8ce411013e8cd0aa8bab.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="只靠Github和Vercel的速度还是有些捉襟见肘，因此再增加一条Coding来为国内访问节点提供线路。"></a><div class="content"><a class="title" href="/posts/54c08a4b/" title="使用Coding和Github来实现双线部署">使用Coding和Github来实现双线部署</a><time datetime="2020-09-21" title="发表于 2020-09-21">2020-09-21</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/803c5fab/" title="双系统 Hexo和github的常用命令行归纳"><img src="" data-lazy-src="https://img.zcool.cn/community/014b6b61e1626511013f01cd5157ce.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="双系统 Hexo和github的常用命令行归纳"></a><div class="content"><a class="title" href="/posts/803c5fab/" title="双系统 Hexo和github的常用命令行归纳">双系统 Hexo和github的常用命令行归纳</a><time datetime="2019-04-12" title="发表于 2019-04-12">2019-04-12</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/812734f8/" title="使用第三方托管服务来加速博客，能够有效改善访问慢的情况。"><img src="" data-lazy-src="https://img.zcool.cn/community/014b6b61e1626511013f01cd5157ce.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="使用第三方托管服务来加速博客，能够有效改善访问慢的情况。"></a><div class="content"><a class="title" href="/posts/812734f8/" title="使用第三方托管平台部署博客">使用第三方托管平台部署博客</a><time datetime="2022-12-06" title="发表于 2022-12-06">2022-12-06</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/e5502ef6/" title="Ubuntu下搭建Hexo+github环境。"><img src="" data-lazy-src="https://img.zcool.cn/community/01a6b161e1626511013f01cd9953a2.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="Ubuntu下搭建Hexo+github环境。"></a><div class="content"><a class="title" href="/posts/e5502ef6/" title="Ubuntu:Hexo+github搭建个人博客">Ubuntu:Hexo+github搭建个人博客</a><time datetime="2019-04-11" title="发表于 2019-04-11">2019-04-11</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/6ef63e2d/" title="Windows系统下搭建Hexo+github的教程，包括主题配置以及博客管理。"><img src="" data-lazy-src="https://img.zcool.cn/community/01f28461e1626511013f01cd1d05d8.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="Windows系统下搭建Hexo+github的教程，包括主题配置以及博客管理。"></a><div class="content"><a class="title" href="/posts/6ef63e2d/" title="Win10:Hexo+github搭建个人博客">Win10:Hexo+github搭建个人博客</a><time datetime="2019-04-09" title="发表于 2019-04-09">2019-04-09</time></div></div><div class="aside-list-item"><a class="thumbnail" href="/posts/f08df520/" title="重写了一个侧栏作者卡片。搭配侧栏卡片修改一起使用。"><img src="" data-lazy-src="https://img.zcool.cn/community/01a6b161e1626511013f01cd9953a2.jpg?x-oss-process=image/auto-orient,1/resize,m_lfit,w_1280,limit_1/sharpen,100/format,webp/quality,q_100" alt="重写了一个侧栏作者卡片。搭配侧栏卡片修改一起使用。"></a><div class="content"><a class="title" href="/posts/f08df520/" title="源计划-方舟：作者卡片">源计划-方舟：作者卡片</a><time datetime="2022-12-31" title="发表于 2022-12-31">2022-12-31</time></div></div></div></div></div></div></main><footer id="footer"><div id="ark-footer-wraper"><div class="ark-footer-container"><div class="ark-footer-left-corner"><div id="ark-footer-bdage-container"><div class="ark-footer-bdage swiper-wrapper"><a class="ark-bdage-item swiper-slide" href="https://hexo.io/" rel="external nofollow noreferrer" title="博客框架为Hexo_v6.2.0" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-hexo"></use></svg><span>Frame-Hexo</span></a><a class="ark-bdage-item swiper-slide" href="https://butterfly.js.org/" rel="external nofollow noreferrer" title="主题版本Butterfly_v4.4.0" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-Butterfly"></use></svg><span>Theme-Butterfly</span></a><a class="ark-bdage-item swiper-slide" href="https://www.jsdelivr.com/" rel="external nofollow noreferrer" title="本站使用JsDelivr为静态资源提供CDN加速" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-jsdelivr"></use></svg><span>CDN-jsDelivr</span></a><a class="ark-bdage-item swiper-slide" href="https://console.dogecloud.com/" rel="external nofollow noreferrer" title="本网站由多吉云提供CDN加速服务" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-DOGE"></use></svg><span>CDN-dogecloud</span></a><a class="ark-bdage-item swiper-slide" href="https://beian.miit.gov.cn" title="本站已在工信部备案，备案号浙ICP备-2021026687号" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-a-255_icp-license"></use></svg><span>ICP-2021026687-1</span></a><a class="ark-bdage-item swiper-slide" href="https://icp.gov.moe/?keyword=20212887" title="本站已加入萌ICP豪华套餐，萌ICP备20212887号" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-space_demo_equipment"></use></svg><span>moeICP-20212887</span></a><a class="ark-bdage-item swiper-slide" href="https://www.netlify.com/" rel="external nofollow noreferrer" title="本站默认线路托管于Netlify" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-netlify"></use></svg><span>Hosted-Netlify</span></a><a class="ark-bdage-item swiper-slide" href="https://github.com/" rel="external nofollow noreferrer" title="本站项目由Github托管" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-GitHub"></use></svg><span>Source-Github</span></a><a class="ark-bdage-item swiper-slide" href="http://creativecommons.org/licenses/by-nc-sa/4.0/" rel="external nofollow noreferrer" title="本站采用知识共享署名-非商业性使用-相同方式共享4.0国际许可协议进行许可" target="_blank"><svg class="icon ark-decoration" aria-hidden="true"><use xlink:href="#icon-copyright"></use></svg><span>Copyright-BY-NC-SA-4</span></a></div></div><div class="ark-footer-copyright">&copy;2016 - 2023 By Akilar</div><a class="ark-footer-record" target="_blank" rel="noopener" href="https://beian.miit.gov.cn" title="浙ICP备-2021026687号">浙ICP备-2021026687号</a></div><div class="ark-footer-right-corner"><div id="workboard"></div><script async src="/js/custom/runtime.js"></script></div></div></div></footer></div><div id="rightside"><div id="rightside-config-hide"><button id="readmode" type="button" title="阅读模式"><i class="fas fa-book-open faa-pulse animated-hover"></i><span>阅读模式</span></button><button id="translateLink" type="button" title="简繁转换"><i>繁</i><span>简繁转换</span></button><a class="icon-V hidden" onclick="switchNightMode()" title="昼夜切换"><svg class="faa-pulse animated-hover" width="25" height="25" viewBox="0 0 1024 1024"><use id="modeicon" xlink:href="#icon-moon"></use></svg><span>昼夜切换</span></a><button id="hide-aside-btn" type="button" title="侧栏显隐"><i class="fas fa-arrows-alt-h faa-pulse animated-hover"></i><span>侧栏显隐</span></button><button id="SAO_Utils_Switch" type="button" title="右键开关" onclick="panelAudio(),SAOSwitch()"><i class="fas fa-mouse faa-pulse animated-hover"></i><span>右键开关</span></button><button id="SAO_Utils_Refresh" type="button" title="点击刷新" onclick="panelAudio(),fetchCommits()"><i class="fa-solid fa-arrows-rotate faa-pulse animated-hover"></i><span>点击刷新</span></button></div><div id="rightside-config-show"><button id="rightside_config" type="button" title="设置"><i class="fas fa-cog fa-spin faa-pulse animated-hover"></i><span>设置</span></button><button id="ranklist_show" type="button" title="打赏榜单" onclick="panelAudio(),RanklistBtn()"><i class="fas fa-fire-alt faa-pulse animated-hover"></i><span>打赏榜单</span></button><button class="close" id="mobile-toc-button" type="button" title="目录"><i class="fas fa-list-ul faa-pulse animated-hover"></i><span>目录</span></button><button id="chat_btn" type="button" title="与我联系"><i class="fas fa-sms faa-pulse animated-hover"></i><span>与我联系</span></button><button id="to_comment" type="button" title="直达评论" onclick="FixedCommentBtn()"><i class="fas fa-comments faa-pulse animated-hover"></i><span>直达评论</span></button><button id="go-up" type="button" title="回到顶部"><i class="fas fa-arrow-up faa-pulse animated-hover"></i><span>回到顶部</span></button></div></div><div id="algolia-search"><div class="search-dialog"><nav class="search-nav"><span class="search-dialog-title">搜索</span><button class="search-close-button"><i class="fas fa-times"></i></button></nav><div class="search-wrap"><div id="algolia-search-input"></div><hr><div id="algolia-search-results"><div id="algolia-hits"></div><div id="algolia-pagination"></div><div id="algolia-info"><div class="algolia-stats"></div><div class="algolia-poweredBy"></div></div></div></div></div><div id="search-mask"></div></div><div><script async src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/async.js"></script><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/utils.js"></script><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/main.js"></script><script defer src="https://npm.elemecdn.com/swiper@8.4.2/swiper-bundle.min.js"></script><script defer data-pjax src="/js/custom/swiper_init.js"></script><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/tw_cn.js"></script><script src="https://npm.elemecdn.com/medium-zoom@1.0.6/dist/medium-zoom.min.js"></script><script src="https://npm.elemecdn.com/instant.page@5.1.1/instantpage.js" type="module"></script><script src="https://npm.elemecdn.com/vanilla-lazyload@17.3.1/dist/lazyload.iife.min.js"></script><script src="https://npm.elemecdn.com/node-snackbar@0.1.16/dist/snackbar.min.js"></script><script src="https://npm.elemecdn.com/algoliasearch@4.14.2/dist/algoliasearch-lite.umd.js"></script><script src="https://npm.elemecdn.com/instantsearch.js@4.44.0/dist/instantsearch.production.min.js"></script><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/search/algolia.js"></script><div class="pjax-reload"><script async>var preloader={endLoading:()=>{if(document.body.style.overflow="auto",document.getElementById("loading-box").style.transition="opacity 3s",document.getElementById("loading-box").style.opacity="0",setTimeout((function(){document.getElementById("loading-box").classList.add("loaded")}),3e3),sessionStorage.getItem("isReload"))return!0;sessionStorage.setItem("isReload",!0),SAONotify("Welcome","欢迎光临糖果屋<br>愿你享受愉快的一天")},initLoading:()=>{document.body.style.overflow="",document.getElementById("loading-box").style.transition="",document.getElementById("loading-box").style.opacity="1",document.getElementById("loading-box").classList.remove("loaded")}};window.addEventListener("load",()=>{preloader.endLoading()}),document.getElementById("loading-box").addEventListener("click",()=>{preloader.endLoading()}),setTimeout((function(){preloader.endLoading()}),3e3)</script></div><div class="js-pjax"><script>(()=>{const t=()=>{twikoo.init(Object.assign({el:"#twikoo-wrap",envId:"https://twikoo-service.akilar.top",region:"",onCommentLoaded:function(){btf.loadLightbox(document.querySelectorAll("#twikoo .tk-content img:not(.tk-owo-emotion)"))}},null))},o=()=>{"object"!=typeof twikoo?getScript("https://npm.elemecdn.com/twikoo@1.6.5/dist/twikoo.all.min.js").then(t):setTimeout(t,0)};btf.loadComment(document.getElementById("twikoo-wrap"),o)})()</script></div><script>window.addEventListener("load",()=>{const e=e=>{let t="";if(e.length)for(let n=0;n<e.length;n++){t+="<div class='aside-list-item'>";{const a="data-lazy-src";t+=`<a href='${e[n].url}' class='thumbnail'><img ${a}='${e[n].avatar}' alt='${e[n].nick}'></a>`}t+=`<div class='content'>\n        <a class='comment' href='${e[n].url}' title='${e[n].content}'>${e[n].content}</a>\n        <div class='name'><span>${e[n].nick} / </span><time datetime="${e[n].date}">${btf.diffDate(e[n].date,!0)}</time></div>\n        </div></div>`}else t+="没有评论";let n=document.querySelector("#card-newest-comments .aside-list");n.innerHTML=t,window.lazyLoadInstance&&window.lazyLoadInstance.update(),window.pjax&&window.pjax.refresh(n)},t=()=>{if(document.querySelector("#card-newest-comments .aside-list")){const t=saveToLocal.get("twikoo-newest-comments");t?e(JSON.parse(t)):(()=>{const t=()=>{twikoo.getRecentComments({envId:"https://twikoo-service.akilar.top",region:"",pageSize:5,includeReply:!0}).then((function(t){const n=t.map(e=>{return{content:(t=e.comment,""===t||(t=(t=(t=(t=t.replace(/<img.*?src="(.*?)"?[^\>]+>/gi,"[图片]")).replace(/<a[^>]+?href=["']?([^"']+)["']?[^>]*>([^<]+)<\/a>/gi,"[链接]")).replace(/<pre><code>.*?<\/pre>/gi,"[代码]")).replace(/<[^>]+>/g,"")).length>150&&(t=t.substring(0,150)+"..."),t),avatar:e.avatar,nick:e.nick,url:e.url+"#"+e.id,date:new Date(e.created).toISOString()};var t});saveToLocal.set("twikoo-newest-comments",JSON.stringify(n),10/1440),e(n)})).catch((function(e){document.querySelector("#card-newest-comments .aside-list").innerHTML="无法获取评论，请确认相关配置是否正确"}))};"object"==typeof twikoo?t():getScript("https://npm.elemecdn.com/twikoo@1.6.5/dist/twikoo.all.min.js").then(t)})()}};t(),document.addEventListener("pjax:complete",t)})</script><script src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/sun_moon.js" async></script><script async data-pjax src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/SAO-NAV.js"></script><script>WIDGET={CONFIG:{modules:"012",background:"5",tmpColor:"FFFFFF",tmpSize:"16",cityColor:"FFFFFF",citySize:"16",aqiColor:"FFFFFF",aqiSize:"16",weatherIconSize:"24",alertIconSize:"18",padding:"10px 10px 10px 10px",shadow:"0",language:"auto",fixed:"false",vertical:"top",horizontal:"left",key:"3da94e567f5e4e88baf90f066f0893c2"}}</script><script defer data-pjax src="https://widget.heweather.net/simple/static/js/he-simple.js?v=1.4.0"></script><script async src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/random.js"></script><script defer src="https://at.alicdn.com/t/c/font_3344355_e443xsjcmum.js"></script><script src="//code.tidio.co/wgamdwbirypo8casl6rjgtfbs47ny3s7.js" async></script><script>function onTidioChatApiReady(){window.tidioChatApi.hide(),window.tidioChatApi.on("close",(function(){window.tidioChatApi.hide()}))}window.tidioChatApi?window.tidioChatApi.on("ready",onTidioChatApiReady):document.addEventListener("tidioChat-ready",onTidioChatApiReady);var chatBtnFn=()=>{document.getElementById("chat_btn").addEventListener("click",(function(){window.tidioChatApi.show(),window.tidioChatApi.open()}))};chatBtnFn()</script><script src="https://npm.elemecdn.com/pjax@0.2.8/pjax.min.js"></script><script>let pjaxSelectors=["head > title","#config-diff","#body-wrap","#rightside-config-hide","#rightside-config-show",".js-pjax","#web_bg","#fixedcard-dashboard"];var pjax=new Pjax({elements:'a:not([target="_blank"])',selectors:pjaxSelectors,cacheBust:!1,analytics:!1,scrollRestoration:!1});document.addEventListener("pjax:send",(function(){if(window.tocScrollFn&&window.removeEventListener("scroll",window.tocScrollFn),window.scrollCollect&&window.removeEventListener("scroll",scrollCollect),"object"==typeof preloader&&preloader.initLoading(),document.getElementById("rightside").style.cssText="opacity: ''; transform: ''",window.aplayers)for(let e=0;e<window.aplayers.length;e++)window.aplayers[e].options.fixed||window.aplayers[e].destroy();"object"==typeof typed&&typed.destroy();const e=document.body.classList;e.contains("read-mode")&&e.remove("read-mode"),"object"==typeof disqusjs&&disqusjs.destroy()})),document.addEventListener("pjax:complete",(function(){window.refreshFn(),document.querySelectorAll("script[data-pjax], .pjax-reload script").forEach(e=>{const t=document.createElement("script"),o=e.text||e.textContent||e.innerHTML||"";Array.from(e.attributes).forEach(e=>t.setAttribute(e.name,e.value)),t.appendChild(document.createTextNode(o)),e.parentNode.replaceChild(t,e)}),GLOBAL_CONFIG.islazyload&&window.lazyLoadInstance.update(),"function"==typeof chatBtnFn&&chatBtnFn(),"function"==typeof panguInit&&panguInit(),"function"==typeof gtag&&gtag("config","",{page_path:window.location.pathname}),"object"==typeof _hmt&&_hmt.push(["_trackPageview",window.location.pathname]),"function"==typeof loadMeting&&document.getElementsByClassName("aplayer").length&&loadMeting(),"object"==typeof Prism&&Prism.highlightAll(),"object"==typeof preloader&&preloader.endLoading()})),document.addEventListener("pjax:error",e=>{404===e.request.status&&pjax.loadUrl("/404.html")})</script><script>"serviceWorker"in navigator&&(navigator.serviceWorker.controller&&navigator.serviceWorker.addEventListener("controllerchange",(function(){fetch("/json/commits.json").then(e=>e.json().then(e=>{for(var r=e,o=0;o<r.length;o++){r[o];var t=o+1+"."+r[o].commit.message;if(o<1)var n=t;else n=n+"<br>"+t}SAONotify("Latest Update",n,"location.reload(true);")})).catch(console.error)})),window.addEventListener("load",(function(){navigator.serviceWorker.register("/sw.js")})))</script><div id="SAO-back"><div id="SAO-menu"><div id="SAO-menu-content"><div class="utils-list"><div class="utils-list-item"><div class="user-panel" style="top:undefined"><div class="user-panel-name">Friends</div><div class="user-panel-img"><img src="" data-lazy-src="/img/info.png"></div><div class="user-panel-properties">Welcome to Akilar の Candyhome !</div></div><i class="fas fa-address-book" onclick="panelAudio(),UtilsClick()"></i><div class="menu-list" style="top:-83px"><div class="menu-list-item"><i class="fa fa-link" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/link/")}),500)'>Link</i></div><div class="menu-list-item"><i class="fas fa-fire-alt" onclick="clickAudio(),setTimeout((function(){SAOclose(),RanklistBtn()}),500)">Pantner</i></div></div></div><div class="utils-list-item"><div class="user-panel" style="top:undefined"><div class="user-panel-name">Help</div><div class="user-panel-img"><img src="" data-lazy-src="/img/info.png"></div><div class="user-panel-properties"><h4>Anything can I help you ?</h4><p>Tidio：开启在线聊天窗<br>Comment：直达评论区或留言板<br>Candyhome：加入糖果屋QQ群</p></div></div><i class="fa fa-question-circle" onclick="panelAudio(),UtilsClick()"></i><div class="menu-list" style="top:-103px"><div class="menu-list-item"><i class="fa fa-comment-dots" onclick="clickAudio(),setTimeout((function(){SAOclose(),openTidio()}),500)">Tidio</i></div><div class="menu-list-item"><i class="fa fa-comments" onclick="clickAudio(),setTimeout((function(){SAOclose(),FixedCommentBtn()}),500)">Comments</i></div><div class="menu-list-item"><i class="fa fa-user-friends" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("https://jq.qq.com/?_wv=1027&amp;k=a08BZRzs")}),500)'>Candyhome</i></div></div></div><div class="utils-list-item"><div class="user-panel" style="top:undefined"><div class="user-panel-name">Menu</div><div class="user-panel-img"><img src="" data-lazy-src="/img/info.png"></div><div class="user-panel-properties">The menu of my blog</div></div><i class="fa fa-tasks" onclick="panelAudio(),UtilsClick()"></i><div class="menu-list" style="top:-163px"><div class="menu-list-item"><i class="fa fa-home" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("https://blog.akilar.top/")}),500)'>Home</i></div><div class="menu-list-item"><i class="fa fa-folder-open" onclick="panelAudio(),MenusClick()">Document</i><div class="menu-child" style="top:-100px"><div class="menu-list-child"><i class="fa fa-file-invoice" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/posts/f99b208/")}),500)'>Beautify</i></div><div class="menu-list-child"><i class="fa fa-file-invoice" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/posts/7c16c4bb/")}),500)'>Optimize</i></div><div class="menu-list-child"><i class="fa fa-file-invoice" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/posts/615e2dec/")}),500)'>Tag_Plugins</i></div><div class="menu-list-child"><i class="fa fa-file-invoice" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/posts/6ef63e2d/")}),500)'>Construct</i></div></div></div><div class="menu-list-item"><i class="fa fa-blog" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/")}),500)'>Blog</i></div><div class="menu-list-item"><i class="fa fa-archive" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/archives/")}),500)'>Archives</i></div><div class="menu-list-item"><i class="fa fa-folder-open" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/categories/")}),500)'>Categoties</i></div><div class="menu-list-item"><i class="fa fa-tags" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/tags/")}),500)'>Tags</i></div></div></div><div class="utils-list-item"><div class="user-panel" style="top:undefined"><div class="user-panel-name">Options</div><div class="user-panel-img"><img src="" data-lazy-src="/img/info.png"></div><div class="user-panel-properties"><h4>Some userful scripts</h4><p>Random： 随机跳转站内文章<br>Search： 打开搜索窗口</p>Refresh： 刷新缓存</div></div><i class="fa fa-tools" onclick="panelAudio(),UtilsClick()"></i><div class="menu-list" style="top:-103px"><div class="menu-list-item"><i class="fa fa-random" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("/toRandomPost()")}),500)'>Random</i></div><div class="menu-list-item"><i class="fa fa-search" onclick="clickAudio(),setTimeout((function(){SAOclose(),openSearch()}),500)">Search</i></div><div class="menu-list-item"><i class="fa-solid fa-arrows-rotate" onclick='clickAudio(),setTimeout((function(){SAOclose(),SAONotify("Refresh","即将为您刷新页面缓存","location.reload(true);")}),500)'>Refresh</i></div></div></div><div class="utils-list-item"><div class="user-panel"><div class="user-panel-name">Instructions</div><div class="user-panel-img"><img src="" data-lazy-src="/img/siteicon/favicon.png"></div><div class="user-panel-properties"><h4>欢迎使用SAO_Utils_Web 2.0</h4><p>点按选项可以持续显示下级菜单。您可以通过按住<kbd>ctrl</kbd>+<kbd>右键</kbd>来恢复使用原生右键菜单，更多内容可点击右侧Option按钮访问教程或Help按钮加入糖果屋QQ群。</p><center>©Akilarの糖果屋</center></div></div><i class="fa fa-cog" onclick="panelAudio(),UtilsClick()"></i><div class="menu-list" style="top:-103px"><div class="menu-list-item"><i class="fa fa-tools" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("https://akilar.top/posts/fd243d7/")}),500)'>Option</i></div><div class="menu-list-item"><i class="fa fa-question-circle" onclick='clickAudio(),setTimeout((function(){SAOclose(),linkStart("https://jq.qq.com/?_wv=1027&amp;k=a08BZRzs")}),500)'>Help</i></div><div class="menu-list-item"><i class="fa fa-sign-out-alt" onclick="alertAudio(),openLogout()">Logout</i></div></div></div><div class="utils-list-item"><i class="fa fa-power-off" onclick="alertAudio(),SAOKeepOff()" title="永久关闭SAO右键菜单"></i></div></div></div></div></div><div id="SAO-logout"><div class="logout-title">Alert</div><div class="logout-alert">是否确认退出?</div><div class="logout-button"><span class="logout-confirm"><button class="far fa-circle" type="button" name="confirm" onclick="clickAudio(),confirmLogout()"></button></span><span class="logout-cancel"><button class="fa fa-times" type="button" name="cancel" onclick="panelAudio(),cancelLogout()"></button></span></div></div><audio id="SAOlauncher" src="https://npm.elemecdn.com/akilar-candyassets/audio/Launcher.mp3"></audio><audio id="SAOClick" src="https://npm.elemecdn.com/akilar-candyassets/audio/Click.mp3"></audio><audio id="SAOPanel" src="https://npm.elemecdn.com/akilar-candyassets/audio/Panel.mp3"></audio><audio id="SAOAlert" src="https://npm.elemecdn.com/akilar-candyassets/audio/Alert.mp3"></audio><script async src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/SAO_Menu.js"></script><div id="SAO-ranklist"><div class="ranklist-title">Rank list</div><div class="ranklist-main"><div class="master-item"><div class="master-rank"><i class="fa fa-plus" onclick="panelAudio(),RanklistBtn()"></i></div><div class="master-user"><a alt="" href="/">Akilar<div class="rank-reward"><div class="reward-img"><img alt="" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/wechat.png"><a class="reward-text" alt="" href="/null">wechat</a></div><div class="reward-img"><img alt="" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/alipay.png"><a class="reward-text" alt="" href="/null">alipay</a></div></div></a></div><div class="master-data"><div class="master-HP"><div class="HP-fill" style="width:20%"><div class="HP-fill-in"><span>20%</span></div></div></div></div><div class="master-level"><span>270</span><span>|</span><span>1350</span><span>lv.23</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*蓓打赏的￥180">*蓓</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:100%"><div class="HP-fill-in"><span>100.00%</span></div></div></div></div><div class="partner-level"><span>9200</span><span>|</span><span>9200</span><span>lv.180</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢晨打赏的￥8.88">晨</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:88.86%"><div class="HP-fill-in"><span>88.86%</span></div></div></div></div><div class="partner-level"><span>622</span><span>|</span><span>700</span><span>lv.10</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://zfe.space/" data-title="感谢**鄂打赏的￥9.9">**鄂</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:13.76%"><div class="HP-fill-in"><span>13.76%</span></div></div></div></div><div class="partner-level"><span>523</span><span>|</span><span>3800</span><span>lv.72</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*光打赏的￥50">*光</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:92.59%"><div class="HP-fill-in"><span>92.59%</span></div></div></div></div><div class="partner-level"><span>2685</span><span>|</span><span>2900</span><span>lv.54</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*洁打赏的￥30">*洁</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:93.78%"><div class="HP-fill-in"><span>93.78%</span></div></div></div></div><div class="partner-level"><span>1688</span><span>|</span><span>1800</span><span>lv.32</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**焘打赏的￥20">**焘</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:90.92%"><div class="HP-fill-in"><span>90.92%</span></div></div></div></div><div class="partner-level"><span>1182</span><span>|</span><span>1300</span><span>lv.22</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://szsyzx.github.io/" data-title="感谢懒蟲打赏的￥20">懒蟲</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:74.06%"><div class="HP-fill-in"><span>74.06%</span></div></div></div></div><div class="partner-level"><span>1148</span><span>|</span><span>1550</span><span>lv.27</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*i打赏的￥10">*i</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:83.38%"><div class="HP-fill-in"><span>83.38%</span></div></div></div></div><div class="partner-level"><span>667</span><span>|</span><span>800</span><span>lv.12</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.acozycotage.net/" data-title="感谢acozycotage打赏的￥10">acozycotage</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:NaN%"><div class="HP-fill-in"><span>NaN%</span></div></div></div></div><div class="partner-level"><span>NaN</span><span>|</span><span>NaN</span><span>lv.undefined</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*因打赏的￥10">*因</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:62.5%"><div class="HP-fill-in"><span>62.50%</span></div></div></div></div><div class="partner-level"><span>625</span><span>|</span><span>1000</span><span>lv.16</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢H*g打赏的￥10">H*g</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:83.38%"><div class="HP-fill-in"><span>83.38%</span></div></div></div></div><div class="partner-level"><span>667</span><span>|</span><span>800</span><span>lv.12</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**宁打赏的￥10">**宁</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:45.46%"><div class="HP-fill-in"><span>45.46%</span></div></div></div></div><div class="partner-level"><span>591</span><span>|</span><span>1300</span><span>lv.22</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.nesxc.com/" data-title="感谢Nesxc打赏的￥14.88">Nesxc</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:74.42%"><div class="HP-fill-in"><span>74.42%</span></div></div></div></div><div class="partner-level"><span>893</span><span>|</span><span>1200</span><span>lv.20</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢J*y打赏的￥2.56">J*y</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:51.11%"><div class="HP-fill-in"><span>51.11%</span></div></div></div></div><div class="partner-level"><span>230</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.lbihua.cn" data-title="感谢哔哗打赏的￥10">哔哗</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:62.5%"><div class="HP-fill-in"><span>62.50%</span></div></div></div></div><div class="partner-level"><span>625</span><span>|</span><span>1000</span><span>lv.16</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://iori-yimaga.top" data-title="感谢T*0打赏的￥23.3">T*0</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:93.17%"><div class="HP-fill-in"><span>93.17%</span></div></div></div></div><div class="partner-level"><span>1351</span><span>|</span><span>1450</span><span>lv.25</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**飞打赏的￥20">**飞</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:74.06%"><div class="HP-fill-in"><span>74.06%</span></div></div></div></div><div class="partner-level"><span>1148</span><span>|</span><span>1550</span><span>lv.27</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**豪打赏的￥10">**豪</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:83.38%"><div class="HP-fill-in"><span>83.38%</span></div></div></div></div><div class="partner-level"><span>667</span><span>|</span><span>800</span><span>lv.12</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.keyiqingxin.cn" data-title="感谢清心打赏的￥3.88">清心</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:19.42%"><div class="HP-fill-in"><span>19.42%</span></div></div></div></div><div class="partner-level"><span>233</span><span>|</span><span>1200</span><span>lv.20</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢鹿栖打赏的￥20">鹿栖</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:74.06%"><div class="HP-fill-in"><span>74.06%</span></div></div></div></div><div class="partner-level"><span>1148</span><span>|</span><span>1550</span><span>lv.27</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://menglei.xyz" data-title="感谢*夢打赏的￥3">*夢</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:27.33%"><div class="HP-fill-in"><span>27.33%</span></div></div></div></div><div class="partner-level"><span>205</span><span>|</span><span>750</span><span>lv.11</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.ijinse.cn" data-title="感谢锦瑟打赏的￥50">锦瑟</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:69.45%"><div class="HP-fill-in"><span>69.45%</span></div></div></div></div><div class="partner-level"><span>2639</span><span>|</span><span>3800</span><span>lv.72</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://glann.vip" data-title="感谢glann打赏的￥5.01">glann</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:41.75%"><div class="HP-fill-in"><span>41.75%</span></div></div></div></div><div class="partner-level"><span>334</span><span>|</span><span>800</span><span>lv.12</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**忠打赏的￥4.48">**忠</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:89.56%"><div class="HP-fill-in"><span>89.56%</span></div></div></div></div><div class="partner-level"><span>403</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://huran.xyz" data-title="感谢忽然打赏的￥13.14">忽然</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:87.58%"><div class="HP-fill-in"><span>87.58%</span></div></div></div></div><div class="partner-level"><span>832</span><span>|</span><span>950</span><span>lv.15</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢XueZha打赏的￥6.66">XueZha</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:66.57%"><div class="HP-fill-in"><span>66.57%</span></div></div></div></div><div class="partner-level"><span>466</span><span>|</span><span>700</span><span>lv.10</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢*葵打赏的￥6.66">*葵</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:66.57%"><div class="HP-fill-in"><span>66.57%</span></div></div></div></div><div class="partner-level"><span>466</span><span>|</span><span>700</span><span>lv.10</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://tianli-blog.club" data-title="感谢天利打赏的￥40.34">天利</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:77.57%"><div class="HP-fill-in"><span>77.57%</span></div></div></div></div><div class="partner-level"><span>2172</span><span>|</span><span>2800</span><span>lv.52</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://bingmeng158.github.io" data-title="感谢冰梦打赏的￥1.5">冰梦</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:30%"><div class="HP-fill-in"><span>30.00%</span></div></div></div></div><div class="partner-level"><span>135</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://0410wzn.top" data-title="感谢WZN打赏的￥1.35">WZN</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:27.11%"><div class="HP-fill-in"><span>27.11%</span></div></div></div></div><div class="partner-level"><span>122</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢KD打赏的￥1.5">KD</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:30%"><div class="HP-fill-in"><span>30.00%</span></div></div></div></div><div class="partner-level"><span>135</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**庆打赏的￥3.5">**庆</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:70%"><div class="HP-fill-in"><span>70.00%</span></div></div></div></div><div class="partner-level"><span>315</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://www.sunguoqi.com" data-title="感谢小孙打赏的￥5.2">小孙</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:52%"><div class="HP-fill-in"><span>52.00%</span></div></div></div></div><div class="partner-level"><span>364</span><span>|</span><span>700</span><span>lv.10</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.nalex.top" data-title="感谢rootlex打赏的￥4">rootlex</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:80%"><div class="HP-fill-in"><span>80.00%</span></div></div></div></div><div class="partner-level"><span>360</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://dreamfall.cn" data-title="感谢梦落打赏的￥1.88">梦落</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:37.56%"><div class="HP-fill-in"><span>37.56%</span></div></div></div></div><div class="partner-level"><span>169</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.cyfan.top" data-title="感谢CYF打赏的￥1.5">CYF</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:30%"><div class="HP-fill-in"><span>30.00%</span></div></div></div></div><div class="partner-level"><span>135</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢一悲打赏的￥2.5">一悲</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:41.6%"><div class="HP-fill-in"><span>41.60%</span></div></div></div></div><div class="partner-level"><span>208</span><span>|</span><span>500</span><span>lv.6</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://hexo.cf" data-title="感谢八神打赏的￥10">八神</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:83.38%"><div class="HP-fill-in"><span>83.38%</span></div></div></div></div><div class="partner-level"><span>667</span><span>|</span><span>800</span><span>lv.12</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://noionion.top" data-title="感谢贰猹打赏的￥20">贰猹</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:90.92%"><div class="HP-fill-in"><span>90.92%</span></div></div></div></div><div class="partner-level"><span>1182</span><span>|</span><span>1300</span><span>lv.22</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://blog.slqwq.cn" data-title="感谢Hajeekn打赏的￥10">Hajeekn</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:66.63%"><div class="HP-fill-in"><span>66.63%</span></div></div></div></div><div class="partner-level"><span>633</span><span>|</span><span>950</span><span>lv.15</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" target="_blank" rel="noopener external nofollow noreferrer" href="https://baokan0.com" data-title="感谢baokan0打赏的￥20">baokan0</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:95.2%"><div class="HP-fill-in"><span>95.20%</span></div></div></div></div><div class="partner-level"><span>1190</span><span>|</span><span>1250</span><span>lv.21</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢h*d打赏的￥10">h*d</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:66.63%"><div class="HP-fill-in"><span>66.63%</span></div></div></div></div><div class="partner-level"><span>633</span><span>|</span><span>950</span><span>lv.15</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢**航打赏的￥10">**航</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:66.63%"><div class="HP-fill-in"><span>66.63%</span></div></div></div></div><div class="partner-level"><span>633</span><span>|</span><span>950</span><span>lv.15</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢I*u打赏的￥2">I*u</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:40%"><div class="HP-fill-in"><span>40.00%</span></div></div></div></div><div class="partner-level"><span>180</span><span>|</span><span>450</span><span>lv.5</span></div></div><div class="partner-item"><div class="partner-rank"></div><div class="partner-user"><a alt="" href="javascript:void(0);" rel="external nofollow noreferrer" data-title="感谢7*i打赏的￥1">7*i</a></div><div class="partner-data"><div class="partner-HP"><div class="HP-fill" style="width:20%"><div class="HP-fill-in"><span>20.00%</span></div></div></div></div><div class="partner-level"><span>90</span><span>|</span><span>450</span><span>lv.5</span></div></div></div></div><script async src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/SAO_ranklist.js"></script><div class="pjax-reload"><script async>for(var arr=document.getElementsByClassName("recent-post-item"),i=0;i<arr.length;i++)arr[i].classList.add("wow"),arr[i].classList.add("animate__zoomIn"),arr[i].setAttribute("data-wow-duration",""),arr[i].setAttribute("data-wow-delay",""),arr[i].setAttribute("data-wow-offset",""),arr[i].setAttribute("data-wow-iteration","")</script><script async>for(var arr=document.getElementsByClassName("card-widget"),i=0;i<arr.length;i++)arr[i].classList.add("wow"),arr[i].classList.add("animate__zoomIn"),arr[i].setAttribute("data-wow-duration",""),arr[i].setAttribute("data-wow-delay",""),arr[i].setAttribute("data-wow-offset",""),arr[i].setAttribute("data-wow-iteration","")</script><script async>for(var arr=document.getElementsByClassName("article-sort-item"),i=0;i<arr.length;i++)arr[i].classList.add("wow"),arr[i].classList.add("animate__zoomIn"),arr[i].setAttribute("data-wow-duration",""),arr[i].setAttribute("data-wow-delay",""),arr[i].setAttribute("data-wow-offset",""),arr[i].setAttribute("data-wow-iteration","")</script><script async>for(var arr=document.getElementsByClassName("flink-list-card"),i=0;i<arr.length;i++)arr[i].classList.add("wow"),arr[i].classList.add("animate__flipInY"),arr[i].setAttribute("data-wow-duration","1s"),arr[i].setAttribute("data-wow-delay",""),arr[i].setAttribute("data-wow-offset",""),arr[i].setAttribute("data-wow-iteration","")</script></div><script defer src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/wow.min.js"></script><script defer src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/wow_init.js"></script><div id="fixedcard-dashboard"><button class="fixedcard-activebtn" type="button" title="用户信息" onclick="FixedCardWidget(&quot;class&quot;,&quot;card-author&quot;,&quot;0&quot;)"><i class="fas fa-address-book"></i></button><button class="fixedcard-activebtn" type="button" title="相关推荐" onclick="FixedCardWidget(&quot;class&quot;,&quot;card-recommend-post&quot;,&quot;0&quot;)"><i class="fas fa-dharmachakra"></i></button><div class="fixedcard-user-avatar fixedcard-activebtn" onclick="RemoveFixedCardWidget()"><img class="fixedcard-user-avatar-img" src="" data-lazy-src="https://npm.elemecdn.com/akiblog@1.0.1/img/author.webp" title="Akilar"></div></div><script defer data-pjax src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/fixed_card_widget.js"></script><script defer data-pjax src="https://npm.elemecdn.com/akiblog@1.0.1/js/custom/fixed_comment.js"></script></div><script>var fdata={apiurl:"/json/akifcircle.json",initnumber:20,stepnumber:10,error_img:"https://npm.elemecdn.com/akilar-candyassets/image/404.gif"};localStorage.setItem("fdatalist",JSON.stringify(fdata))</script><script defer src="https://npm.elemecdn.com/hexo-filter-fcircle/assets/js/fetch.js"></script><script data-pjax src="https://npm.elemecdn.com/hexo-filter-gitcalendar/lib/gitcalendar.js"></script><script data-pjax>function gitcalendar_injector_config(){document.getElementById("recent-posts").insertAdjacentHTML("afterbegin",'<div class="recent-post-item" id="gitcalendarBar" style="width:100%;height:auto;padding:10px;"><style>#git_container{min-height: 280px}@media screen and (max-width:650px) {#git_container{min-height: 0px}}</style><div id="git_loading" style="width:10%;height:100%;margin:0 auto;display: block;"><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 50 50" style="enable-background:new 0 0 50 50" xml:space="preserve"><path fill="#d0d0d0" d="M25.251,6.461c-10.318,0-18.683,8.365-18.683,18.683h4.068c0-8.071,6.543-14.615,14.615-14.615V6.461z" transform="rotate(275.098 25 25)"><animatetransform attributeType="xml" attributeName="transform" type="rotate" from="0 25 25" to="360 25 25" dur="0.6s" repeatCount="indefinite"></animatetransform></path></svg><style>#git_container{display: none;}</style></div><div id="git_container"></div></div>'),console.log("已挂载gitcalendar")}document.getElementById("recent-posts")&&"/"===location.pathname&&(gitcalendar_injector_config(),GitCalendarInit("/json/akicalendar.json",["#e4dfd7","#f9f4dc","#f7e8aa","#f7e8aa","#f8df72","#fcd217","#fcc515","#f28e16","#fb8b05","#d85916","#f43e06"],"Akilarlxh"))</script></body></html>